twitter-export icon indicating copy to clipboard operation
twitter-export copied to clipboard

DM solution not compatible with Twitter ToS?

Open epicfaace opened this issue 4 years ago • 15 comments

Twitter's automation rules say:

C. Automated Direct Messages Sending automated Direct Messages to users

You may not send unsolicited Direct Messages in a bulk or automated manner, and should be thoughtful about the frequency with which you contact users via Direct Message. You may send automated Direct Messages to users so long as: in advance of sending the Direct Message, the recipient(s) have requested or have clearly indicated an intent on Twitter to be contacted by you via Direct Message, for example by sending you a Direct Message; and you provide a clear and easy way for such users to opt-out of receiving automated Direct Messages, and promptly honor all such opt-out requests. The fact that a user is technically able to receive a Direct Message from you (e.g. because the user follows you, has enabled the ability to receive Direct Messages from any account, or because the user is in a pre-existing Direct Message conversation with you) does not necessarily mean they have requested or expect to receive automated Direct Messages from you.

It appears that merely implementing the DM solution (the "mass DM approach" outlined in the README) is not compatible with Twitter's ToS, unless followers that receive the DMs have explicitly given consent to send them DMs (such as sending you a DM, or clicking on a link, etc.).

Is my understanding correct? @balajis

epicfaace avatar Jun 14 '20 16:06 epicfaace

I think no legal solution sill be possible. The main resource Twitter has is the users. They won’t want to give that up.

NightMachinery avatar Jun 14 '20 20:06 NightMachinery

mmm maybe there is a hiatus, you are sending 1 DM message to 1 user each, not multiple messages ;-), or you have to enter on each message, but that defeats the purpose I guess

DennisRutjes avatar Jun 14 '20 21:06 DennisRutjes

The Twitter TOS does make the bulk DM solution seem illegal, and any app that violates it will get its own dev key yanked pretty fast. I'll have my husband (lawyer) look over the TOS tomorrow and see if he sees any leeway here. Otherwise perhaps scraping from bios/websites is the only way to do it.

mspanish avatar Jun 15 '20 07:06 mspanish

Using the official API:

Time to download all of Balaji's followers: 30 min Time to DM all of Balaji's followers: 220 days

Given that send DMs in this way is possibly against ToS, there's a good chance of getting banned before 220 days. Would be great if there was a solution for sending DMs outside of the official Twitter API.

Scraping bios/websites seems pretty unreliable, or at least must have a pretty low % with an email address?

bconnorwhite avatar Jun 15 '20 15:06 bconnorwhite

Getting followers ids does not give you enough information to sort them by priority - how about the time to download full record for each id?

mspanish avatar Jun 15 '20 18:06 mspanish

@mspanish if you have Twitter OAuth user credentials, you can convert ~90k user ids into full Twitter user objects every 15 minutes via the users/lookup endpoint. See my solution for a full example of this approach: https://github.com/saasify-sh/twitter-flock

transitive-bullshit avatar Jun 15 '20 18:06 transitive-bullshit

@transitive-bullshit ah cool I thought the rate was lower for that, thanks.

mspanish avatar Jun 15 '20 18:06 mspanish

You can do 900 calls to users/lookup every 15 min if you have OAuth user creds, and you can include up to 100 comma-separated user ids (or screen names) per call. 😄

It'll be ~30k every 15 minutes if you're not using user oauth credentials btw.

transitive-bullshit avatar Jun 15 '20 18:06 transitive-bullshit

I think there is no easy way around this issue.

  • The automated mass DM approach might get the user's API access suspended (due to the violations of the Automation Rules) or get the message they are trying to share with their followers shadowbanned (as they would be including the same text/link in all the DMs being sent out). Shadowbanning is a particularly significant concern because Twitter is strictly against duplicative or substantially similar content (https://blog.twitter.com/developer/en_us/topics/tips/2018/automation-and-the-use-of-multiple-accounts.html) being shared in an automated manner. I have personally witnessed this happening with a subset of my tweets a few months back, and there was no recourse available to rectify that issue.

  • Also, with the checks and balances that Twitter has in place (like 1000 DM/day limit), the mass DM method might not be a sensible approach for users with large followings as the time to complete the task (of sending the DMs to every follower) will be measured in years.

All that aside, I have also noticed a few positive things which are in favor of the Mass DM approach.

  • There are various tools out there that provide functionalities that automates sending predefined DM to new followers. This could mean there might some relaxation in enforcing Automation Rules for direct messages if things are done in a non-spammy manner (like sending an automated DM only once)

  • In #1, @vasa-develop does mention about an uptick in signups by over 500 users after using this mass DM approach. This could mean that the fear about shadowbanning of duplicate/similar DMs might be misplaced

Lastly, I do think that one-off automated DM to every follower is the best available method for achieving our objective within the constraints imposed by Twitter. Reaching out to followers outside of Twitter (like email) by scrapping that information (aka their email address) from their profiles would require the explicit consent of every follower. But I do worry that for users with a large following, Twitter might not like the mass DM approach as it directly competes with their own offerings (aka Twitter Ads) and they have a sort of financial incentive in restricting such users from reaching out to their own followers free of cost

prayagverma avatar Jun 16 '20 03:06 prayagverma

Time to download all of Balaji's followers: 30 min

@bconnorwhite How does it take only 30 mins?

It seems like the official twitter API only allows you to make 1 request a minute:

  • https://developer.twitter.com/en/docs/accounts-and-users/follow-search-get-users/api-reference/get-followers-list

gg2001 avatar Jun 16 '20 04:06 gg2001

Time to download all of Balaji's followers: 30 min

@bconnorwhite How does it take only 30 mins?

It seems like the official twitter API only allows you to make 1 request a minute:

  • https://developer.twitter.com/en/docs/accounts-and-users/follow-search-get-users/api-reference/get-followers-list

It states Requests / 15-min window (user auth) | 15 This means you can make 15 requests in 15 minutes, each request, however, can have a maximum of 200 users per. This means a total of 3000 users per 15 minutes.

ryandotelliott avatar Jun 16 '20 10:06 ryandotelliott

@gg2001 @DeveloperRyan if you first export the ids of all your followers and then use lookup/users, it's significantly faster than the approach you're talking about.

  • followers/ids can return up to 5k user ids per call => 75k users / 15 minutes
  • users/lookup can batch up to 100 user ids per call and with user oauth credentials that's 900 calls => 90k users / 15 minutes

This has been tested & verified locally via https://github.com/saasify-sh/twitter-flock

transitive-bullshit avatar Jun 16 '20 11:06 transitive-bullshit

@transitive-bullshit I appreciate the advice! I'll go ahead with implementing that method then.

ryandotelliott avatar Jun 16 '20 12:06 ryandotelliott

@epicfaace There are many inconsistent bits in the ToS. I spoke to someone very senior within Twitter and they didn't have objections to trying the mass DM approach out. A big part will be if it's done well enough that folks don't mind it.

That said, I tweeted this out yesterday: https://twitter.com/balajis/status/1272431222485106688

image

image

I took the time to write this up as an alternative approach to mass DM. Let's call it the "affiliate link" approach: https://github.com/balajis/twitter-export#the-affiliate-link-approach

See also here for a proposed generic way to score different approaches: https://github.com/balajis/twitter-export#bounty-scoring

balajis avatar Jun 16 '20 16:06 balajis

@balajis Interesting idea -- thanks!

epicfaace avatar Jun 16 '20 18:06 epicfaace