Twitter is a popular social network where users share messages called tweets. Twitter allows us to mine the data of any user using Twitter API or Tweepy. The data will be tweets extracted from the user. The first thing to do is get the consumer key, consumer secret, access key and access secret from twitter developer available easily for each user. These keys will help the API for authentication.
SavedSearch object in Tweepy module contains the information about a saved search.
Here are the list of attributes in the SavedSearch object :
- id : The ID of the saved search.
- id_str : The ID of the saved search as a string.
- query : The query of the saved search.
- name : The name of the saved search.
- position : The position of the saved search.
- created_at : The time the saved search was created at.
Example : Use
get_saved_search() method to fetch the saved search.
The id of the saved search is : 1272422627047378944 The id_str of the saved search is : 1272422627047378944 The query of the saved search is : Tweepy The name of the saved search is : Tweepy The position of the saved search is : None The saved search was created at : 2020-06-15 06:56:09
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course.