MaelKubli / RTwitterV2

R functions for Twitter's v2 API
MIT License
46 stars 6 forks source link

Add recent_search and refactor search endpoints #5

Closed KentonWhite closed 2 years ago

KentonWhite commented 2 years ago

Hi @MaelKubli,

Your project is a godsend for me! I teach a course at Algonquin College (https://www.algonquincollege.com) where I've been using RTwitter. This recent change where default accounts only work with V2 has been causing real problems (we run the twitter stuff at the end of the term so I've only just discovered this issue).

I really like how clean you have made the interface. I also appreciate that most of your audience will have access to academic licenses and so will use the full search endpoint. Why would anyone want to use the limited recent search endpoint?

Well... my course is a college course and my students are college students. I envision having trouble getting an academic license for the students. Letting my students sign up for the essential account and have instant access to the recent search endpoint would be great (and I think a use case for other academics that would use this in teaching).

I maintain ProjectTemplate (https://github.com/KentonWhite/ProjectTemplate, http://projecttemplate.net) and know first hand how much time maintain a package takes (thank you by the way). I also know that maintainers have a vision for how they want the package to evolve. My preference is if someone wants to add a major feature that they ask before doing the work and submit a PR.

So, would you like if I refactor the current search end point so that the all endpoint is not hardcoded but passed and then create functions exposed to the user that provide archive search and recent search? If so I can get a PR together over the holiday break.

Thanks again!

Kenton

MaelKubli commented 2 years ago

Dear Kenton

I get that it is rather difficult for college students to obtain access to the academic track. Hence, I will add a function for the recent search endpoint in the future. I hope I will have it up and running in the next few hours. It should not take very long as it is very similar to the full archive research!

For the time being I will make it quick and dirty and refactor it later as it is faster to just quickly exchange the endpoint url and copy the function.

All the best, Maël

MaelKubli commented 2 years ago

New Endpoint is now added to the Package! Function is called recent_search and it works very much like the full_archive_search.

KentonWhite commented 2 years ago

Thanks so much! Let me know if you need help with the package. I really like what you have started.