0

I have an option to "invite all" in my device contacts email to use my iOS application through MFMailComposeViewController. Its working fine right now. But i want to know the limitation of recipients can allow in a single mail from Apple. Herewith i added the code to send mails. Here contactList is an array. Assume like this array contains more than 2000 email id's.

@IBAction func act_InviteAllInContacts(sender: AnyObject)
    {
        var contactList : NSMutableArray = NSMutableArray()
        contactList = addressBookClassObj.getContactNames()
        var picker = MFMailComposeViewController()
        picker.mailComposeDelegate = self
        picker.setSubject("APPLICATION NAME")
        picker.setMessageBody("Hi! Checkout this app https://itunes.apple.com/us/app***********", isHTML: true)
        picker.setToRecipients(contactList as [AnyObject])
        presentViewController(picker, animated: true, completion: nil)
    }

Need advice: is it possible to send mails to all the recepient or message will be failure.

Quentin Hayot
  • 7,786
  • 6
  • 45
  • 62
Muthu Sabarinathan
  • 1,198
  • 2
  • 21
  • 49
  • I don't know the answer to your specific question, but in general, Apple builds in safeguards to prevent developers from spamming using their SDK. Sending email to 2000 recipients would definitely qualify as spamming. I bet the limit is more like 50 recipients. Curious that the docs don't talk about limits at all. – Duncan C Aug 10 '15 at 11:57
  • Even if the API allows this, your app would likely be rejected in review if you include an "email entire contact list" feature. In other words, the answer to your question is "Don't do that." – Duncan C Aug 10 '15 at 11:58

1 Answers1

4

Apple's documentation does not refer to any limitation.

However, this is a VERY BAD practice to send an email to 2000 recipient!

  1. You might be denied by your email provider
  2. You might be black listed for spam
  3. If you put your recipient list anywhere else than in the Bcc field (setBccRecipients:), everyone will have access to every email address in your list.

To send that amount of messages, you should really consider to use a Mailing Tool such as Mailchimp.

TL;DR: There might be no limitation, but please don't do that !

Quentin Hayot
  • 7,786
  • 6
  • 45
  • 62