spring-discord-bot icon indicating copy to clipboard operation
spring-discord-bot copied to clipboard

Discord all-purpose bot, made using Spring Boot, JPA, Hibernate, REST, HikariCP. Written for fun, do not take this serious.

Friendly Garbanzo

Discord all-purpose bot, made using Spring Boot, JPA, Hibernate, REST, HikariCP. Written for fun, do not take this serious

Services

Type Badges
Code quality: maintability-icon
Continuous Integration: travis-icon appveyor-icon

Endpoints

Method Optional query parameters Success status codes Error status codes
GET /api/users page, size 200
GET /api/users/by-id/{id} 200 404
GET /api/users/by-name/{name} 200 404

Features

  • [x] Storing all user's data to mysql database
  • [x] Public rest api without oauth
  • [x] Github command, that shows infos about your github profile
  • [x] Commit command - displays commits' count
  • [x] Say command, that talks in json

Configuration

Create file named application.properties in your resource directory, with the following content:

# DATA SOURCE
spring.datasource.url=jdbc:mysql://localhost:3306/garbanzo
spring.datasource.username=root
spring.datasource.password=root
# JPA HIBERNATE
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQLDialect
spring.jpa.properties.hibernate.format_sql=true
spring.jpa.hibernate.use-new-id-generator-mappings=false
spring.jpa.open-in-view=false
# I18N
spring.messages.basename=locale/messages
spring.messages.encoding=UTF-8
spring.messages.fallback-to-system-locale=true
# JDA
jda.discord.token=your discord key
# JACKSON
spring.jackson.serialization.indent_output=true

Contributing

  • fork it
  • create your own branch, like so: command/xx/8ball, where xx are your initials.
  • commit and push your changes
  • create pull request
  • wait for the review

The first rule, the only rule, is that you need use Google Code Style

License

See the License file.