can now properly register agents