Module: Slack::RealTime::Api::Typing

Included in:
Client
Defined in:
lib/slack/real_time/api/typing.rb

Instance Method Summary collapse

Instance Method Details

#typing(options = {}) ⇒ Object

Send a typing indicator to indicate that the user is currently writing a message.

Parameters:

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • :channel (channel)

    Channel to send message to. Can be a public channel, private group or IM channel. Can be an encoded ID, or a name.



12
13
14
15
# File 'lib/slack/real_time/api/typing.rb', line 12

def typing(options = {})
  throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil?
  send_json({ type: 'typing', id: next_id }.merge(options))
end