Complete the authenticate & register API