A court filing shows how FBI agents used a controversial spy tool to investigate the largest terrorism case in Metro Detroit in more than 20 years.