Under federal law, specifically the Electronic Communications Privacy Act (ECPA) and 18 U.S.C. § 2511(2)(d), recording a phone call or conversation is legal if at least one party to the conversation consents to the recording, provided the recording is not made for the purpose of committing a criminal or tortious act. This means that if you are a participant in the conversation, you can record it without informing the other party, unless state law imposes stricter requirements. Federal law also prohibits third parties (those not part of the conversation) from recording without consent, except in specific circumstances like law enforcement with a warrant. Violating federal law can result in up to five years imprisonment and civil damages under 18 U.S.C. § 2520. (underlining added)When a conversation crosses state lines (e.g., a phone call between two states), the stricter state law typically applies to avoid liability, especially if one state requires all-party consent.
They are already doing it without warrants... Everything you say and do on a cellphone is being recorded. Not only that, it is being recorded and sold.
How is it legal? Because when you agree to use their device and service you are waiving all your privacy rights by contract. To use the device you have to legally agree that they can collect and use it all as they like.
Contract law prevails with this.