Per my test, there is no one graph can bother list all Teams connected sites and all files in the site.
You should do this through PowerShell and graph.
1.List all Teams connected sites through PowerShell.
#Connect to SharePoint Service
Connect-SPOService -Url "https://Crescent-admin.sharepoint.com"
#Get All Microsoft Teams Connected Sites
Get-SPOSite -Limit All | Where {$_.IsTeamsConnected -eq $True}
#Get all Teams Channel Connected
Get-SPOSite -Limit All | where {$_.IsTeamsChannelConnected -eq $True}
2.List all files in a site through graph.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.