Coder Social home page Coder Social logo

Comments (5)

PrimalPimmy avatar PrimalPimmy commented on August 28, 2024 6

I would like to work on this issue.

from bots.

PrimalPimmy avatar PrimalPimmy commented on August 28, 2024 3

Okay, so I have made some progress.. Here's the tweet function that I created this function for the tweet.. Not showing my tokens for obvious reasons..

func tweet(ID int64) {
//Initializing twitter API
config := oauth1.NewConfig("consumerKey", "consumerSecret")
token := oauth1.NewToken("accessToken", "accessSecret")
httpClient := config.Client(oauth1.NoContext, token)
Tclient := twitter.NewClient(httpClient)

tweets, resp, err := Tclient.Timelines.HomeTimeline(&twitter.HomeTimelineParams{
	Count: 1,
})
bot.Send(tbot.NewMessage(ID, tweets.Text))

}

But the error here is..
Screenshot from 2020-11-02 18-30-57

Now afaik, the type tweet in the twitter-go package does indeed contain a Text method, given here.. https://godoc.org/github.com/dghubble/go-twitter/twitter#Tweet

So this is the progress so far, but if you can check it out a little, that'd be great too, otherwise it's just almost done I guess.

from bots.

daemon1024 avatar daemon1024 commented on August 28, 2024 2

Hey @PrimalPimmy, Thanks for showing interest in this. If you have any queries regarding setting up or the issue feel free to ask here 😊

from bots.

daemon1024 avatar daemon1024 commented on August 28, 2024

Hey @PrimalPimmy Did you progress with the issue? Feel free to ask if you need any help in implementing it 😄

from bots.

PrimalPimmy avatar PrimalPimmy commented on August 28, 2024

Hey @PrimalPimmy Did you progress with the issue? Feel free to ask if you need any help in implementing it 😄

Slowly getting the grasp of Golang. But still learning about how to implement the twitter API in the bot, if you can provide any useful links for this, that'd be helpful!

from bots.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.