更改SMTP用户密码的自动化

I have a PHP application which send e-mail to users using PHPMAILER, I have allotted with a username and password for authenticating SMTP server. My problem is that every 30 days the password will expire and that need to be changed. So it's difficult to change password manually at every time. If I forgot to change the password in every 30 days then my application will not send e-mails and through error. So is there is any way to automatically change the password? Thanks in advance.