Add id function.