Originally Posted by
Section 107
CBP uses API to identify high-risk passengers and crew members who may pose a risk to border, aviation, or public security; may be a terrorist or suspected terrorist or affiliated with or suspected of being affiliated with terrorists; may be inadmissible; may be a person of interest; may otherwise be engaged in activity in violation of U.S. law; or may be the subject of wants or warrants.
A lot more info here
05-6522.pdf (govinfo.gov) from the Notice of Proposed Rulemaking and the Final Notice about the history and justifications of the APIS.