Hello, @Mani,
Welcome to the Microsoft Q&A platform!
From Exchange's native configuration there isn’t a built‐in mechanism to track when a delegation was assigned (and thus no native “expiry” event) or to automatically trigger reminders based solely on a 60-day interval. Perhaps you can try to handle this directly from Exchange by custom scripting.
Here's a way to automate the delegation and set a reminder using PowerShell:
- Assign Delegation: Use the
Add-MailboxPermission
cmdlet to assign the delegation. - Set a Reminder: You can use a scheduled task to run a PowerShell script that checks for delegations that are about to expire and sends a reminder email.
# Assign delegation
Add-MailboxPermission -Identity "SharedMailbox" -User "DelegateUser" -AccessRights FullAccess -InheritanceType All
# Schedule a task to run after 60 days
$action = New-ScheduledTaskAction -Execute 'Powershell.exe' -Argument '-File "C:\Scripts\CheckDelegation.ps1"'
$trigger = New-ScheduledTaskTrigger -At (Get-Date).AddDays(60) -Once
Register-ScheduledTask -Action $action -Trigger $trigger -TaskName "CheckDelegation"
# Create the CheckDelegation.ps1 script
$scriptContent = @"
# CheckDelegation.ps1
# Script to check delegation and send reminder
# Your logic to check delegation
# Example: Send an email reminder
Send-MailMessage -To "your-email@example.com" -Subject "Delegation Reminder" -Body "Please review the delegation for SharedMailbox." -SmtpServer "smtp.example.com"
"@
Set-Content -Path "C:\Scripts\CheckDelegation.ps1" -Value $scriptContent
This script will:
- Assign the delegation.
- Schedule a task to run a script after 60 days.
- The scheduled script will send a reminder email.
Since it is very difficult for exchange to try to automate on this issue, if it fails, I suggest using Power Automate to finish this. For reference, please refer to Automate Shared Mailbox Requests Using Azure Logic Apps.
(Note: Microsoft provides third-party contact information to help you find additional information about this topic. This contact information may change without notice. Microsoft does not guarantee the accuracy of third-party contact information.)
Should you need more help on this, you can feel free to post back.
If the answer is helpful, please click on “Accept answer” as it could help other members of the Microsoft Q&A community who have similar questions and are looking for solutions.
Thank you for your support and understanding.
Best Wishes,
Alex Zhang