Simply put, the National Security Agency is an intelligence agency. Its purpose is to monitor the world's communications, which it traditionally collected by using spy satellites, taps on cables, and placing listening stations around the world.
In 2008, by making changes to U.S. law, the U.S. Congress enabled the NSA to make U.S. industry complicit in its mission. No longer would the NSA have to rely only on international gathering points. It can now go to domestic companies who hold massive amounts of information on foreigners and order them to submit any information of interest to the NSA. This could include the content of communications, documents, photos, videos, or locations and other so-called metadata -- any information held by the companies. No warrant is required -- though there is a secret court review. But that review's primary purpose appears to be to provide assurances that Americans won't be targeted.