ScanAPI Sample code