Giter Site home page Giter Site logo

scala-slack-bot-core's Introduction

scala-slack-bot-core

Codacy Badge

Akka based library for writing Slack bots in Scala.

For examples, description and ideas take a look at our implementation or blog post.

Developed by Scalac

scala-slack-bot-core's People

Contributors

marioosh avatar pjazdzewski1990 avatar redroy44 avatar willpickard91 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

scala-slack-bot-core's Issues

Possibility to customize spray-json JsonProtocol

Hi,

I'm using slack-scala-bot-core 0.2.1 which depends on spray-json 1..3.1.
No I've added a dependency to akka-http-spray-json 10.0.3 which depends on spray-json 1.3.3.

The problem is that there is an incompatibility in the API between spray-json 1.3.1 and 1.3.3 which causes an error :

java.lang.NoSuchMethodError: spray.json.StandardFormats$class.optionFormat(Lspray/json/StandardFormats;Lspray/json/JsonFormat;)Lspray/json/StandardFormats$OptionFormat;

spray/spray-json#158

A possible fix would be to recompile slack-scala-bot-core with spray-json 1.3.3 but that means I have to embed this version in my project.

Is there a possibility to customize or replace the Unmarshallers object used in ApiActor ?

Thank you

How to get channel ID by name?

The first param of OutboundMessage is a channel id. If the target channel name is known, but not the id, how can we obtain the id?

`OutboundMessage` doesn't escape the newline in JSON

https://github.com/ScalaConsultants/scala-slack-bot-core/blob/master/src/main/scala/io/scalac/slack/common/Messages.scala#L52

If the text contains newline or ", it will break the JSON format.

Example:

val response = OutboundMessage(message.channel, s"""ha","escape":"bad""")
publish(response)

Expected Payload:

{
"id": 1,
"type": "message",
"channel": "D08GG2WJF",
"text": "ha\",\"escape\":\"bad"
} 

Actual Payload:

{
"id": 1,
"type": "message",
"channel": "D08GG2WJF",
"text": "ha","escape":"bad"
} 

Support for threaded messages

I would like to added threaded message support. This will allow bots to respond to a conversation and encapsulate the conversation in a thread. This type of encapsulation makes it a lot easier to follow a conversation on a particular topic, and removes a lot of noise from the channel.

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.