A sealless pump or turbine module having an integral motor or generator, the module comprising: an inlet located at a proximal end of the module, the inlet being on a central axis of the module; an outlet located at a distal end of the module, the outlet being on the central axis of the module; a module housing surrounding the module, the module housing being terminated proximate said outlet by a rear flange of the module housing; a rotor suspended within the module housing; a motor within the module housing configured to drive a rotation of the rotor, or a generator within the module housing configured to be driven by rotation of the rotor, the motor or generator comprising: a stator within a sealed stator housing, the stator comprising at least one electromagnet directed toward the rotor, said stator housing being removably axially, radially, and rotationally fixable to the module housing; a plurality of magnetic devices assembled in a magnet structure that is removably constrained to be axially fixed and rotationally cooperative with the rotor, the magnetic devices being configured by the magnet structure to pass in proximity to the at least one electromagnet as the rotor rotates; a flow path symmetrically distributed about the stator housing, the module being configured to direct a flow of working fluid from the inlet through the flow path to the outlet such that the working fluid is symmetrically distributed about the stator housing as it flows past the stator within the flow path; a plurality of guide vanes provided in the flow path, the guide vanes being fixed to the rear flange and configured to break the flow path into a plurality of separate but symmetric paths until the flow reaches the central axis and flows axially out through the outlet; a female socket penetrating one of the guide vanes and the rear flange; and an electrical port extending from the stator housing and configured for insertion into the female socket to provide a sealed passage through which electrical conductors can be directed from the stator coil to apparatus that is external to the module housing. an inlet located at a proximal end of the module, the inlet being on a central axis of the module; an outlet located at a distal end of the module, the outlet being on the central axis of the module; a module housing surrounding the module, the module housing being terminated proximate said outlet by a rear flange of the module housing; a rotor suspended within the module housing; a motor within the module housing configured to drive a rotation of the rotor, or a generator within the module housing configured to be driven by rotation of the rotor, the motor or generator comprising: a stator within a sealed stator housing, the stator comprising at least one electromagnet directed toward the rotor, said stator housing being removably axially, radially, and rotationally fixable to the module housing; a plurality of magnetic devices assembled in a magnet structure that is removably constrained to be axially fixed and rotationally cooperative with the rotor, the magnetic devices being configured by the magnet structure to pass in proximity to the at least one electromagnet as the rotor rotates; a flow path symmetrically distributed about the stator housing, the module being configured to direct a flow of working fluid from the inlet through the flow path to the outlet such that the working fluid is symmetrically distributed about the stator housing as it flows past the stator within the flow path; a plurality of guide vanes provided in the flow path, the guide vanes being fixed to the rear flange and configured to break the flow path into a plurality of separate but symmetric paths until the flow reaches the central axis and flows axially out through the outlet; a female socket penetrating one of the guide vanes and the rear flange; and an electrical port extending from the stator housing and configured for insertion into the female socket to provide a sealed passage through which electrical conductors can be directed from the stator coil to apparatus that is external to the module housing. a stator within a sealed stator housing, the stator comprising at least one electromagnet directed toward the rotor, said stator housing being removably axially, radially, and rotationally fixable to the module housing; a plurality of magnetic devices assembled in a magnet structure that is removably constrained to be axially fixed and rotationally cooperative with the rotor, the magnetic devices being configured by the magnet structure to pass in proximity to the at least one electromagnet as the rotor rotates; a flow path symmetrically distributed about the stator housing, the module being configured to direct a flow of working fluid from the inlet through the flow path to the outlet such that the working fluid is symmetrically distributed about the stator housing as it flows past the stator within the flow path; a plurality of guide vanes provided in the flow path, the guide vanes being fixed to the rear flange and configured to break the flow path into a plurality of separate but symmetric paths until the flow reaches the central axis and flows axially out through the outlet; a female socket penetrating one of the guide vanes and the rear flange; and an electrical port extending from the stator housing and configured for insertion into the female socket to provide a sealed passage through which electrical conductors can be directed from the stator coil to apparatus that is external to the module housing.