Added API functionality

Can we consolidate this on into a function in the users API?