Added a method for scanning ids.