Skip to content
This repository was archived by the owner on Aug 9, 2026. It is now read-only.

Latest commit

History

16 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

SimpleTwitterBotAPI

A very simple API/Twitter4J wrapper for Twitter bots.

Example

TwitterBotbot = newTwitterBot(); // create a new Twitter bot instanceBehaviourbehaviour = BehaviourBuilder.create()
.listen(
newKeywordEvent("lookingForThisKeyword"), // looking for "lookingForThisKeyword" and "#mySuperCoolHashtag" on TwitternewHashtagEvent("mySuperCoolHashtag") // can also be achieved by calling listen() on the builder multiple times
).filter(
newRTFilter() // exclude tweets that starts with "RT, a lot of bots do this
).react(
newQueuedReplyReaction("Test!", "Test 123")
).build();
bot.addBehaviour(behaviour); // add the behaviour to the bot instance// or do everything in one statementbot.addBehaviour(
BehaviourBuilder.create().listen(
newMentionEvent("miichidk")
).react(
newLikeReaction()
).build()
);
// ... add as many behaviours as you wantbot.start();

Setup

To create a new bot/bot behaviour just orientate on the example code. Authentication works via Twitter4j. Follow the instructions here. To authenticate via ConfigurationBuilder, just pass the built configuration object to the constructor of TwitterBot().

Dependencies

About

A very simple API/Twitter4J wrapper for Twitter bots.

Topics

Resources

Stars

5 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages