Walther Posted October 6 Share Posted October 6 I need to send an email message to my customer and, in cc, to a couple of different foreign email addresses. But it seems to be impossible... The API SendEmail command ( https://developers.whmcs.com/api-reference/sendemail ) allows you to specify just the user ID, and send te message to the email address of that user ID... but does not allow tospecify any CC or CCN address (note. this is possible when you send a message from the WHMCS admin web interface, so it's not a limit of the system but just of the API function). I tried using the PreEmailSendReduceRecipients hook, but it allows just to remove a predefined CC recipient, not to add a new one or redefiny an existing one... Any ideaabout how to do it? 0 Quote Link to comment Share on other sites More sharing options...
Huzaifa Azeem Posted October 31 Share Posted October 31 Have you considered updating the CC field of the email template directly in the database before calling the SendEmail API? Since WHMCS already stores the CC recipients with the email template, you could potentially update that field with the required email addresses before sending the email. The SendEmail API would then use the updated template configuration. However, this approach would need testing, especially if multiple emails are sent simultaneously using the same template, as it could cause recipient conflicts. For fixed CC addresses, configuring them directly in the email template should be sufficient. For dynamic CC addresses, a database-based approach might be worth exploring. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.