The Exchange online eDiscovery function has been moved to Microsoft 365 compliance center.
For this question, I would suggest you used Content Search as below, you need to connect to Security & Compliance first:
$from = "2022-"+((Get-Date).Month-(1).tostring())+"-1"
$to = "2022-"+((Get-Date).Month-(1).tostring())+"-30"
New-ComplianceSearch -Name "TestSearch" -ExchangeLocation "******@domain.onmicrosoft.com" -ContentMatchQuery "(Subject:'Test*') -and (received:$from..$to)"
Start-ComplianceSearch TestSearch
After the search complete, you could use command below to create the export request:
New-ComplianceSearchAction -SearchName "TestSearch" -Export
You could create two Schedule Task, the first task to create the search request, another one create the export request after about 30 minutes.
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.