Class: Line::Bot::Event::Beacon

Inherits:
Base
  • Object
show all
Defined in:
lib/line/bot/event/beacon.rb

Overview

Event object for when a user enters the range of a LINE Beacon.

developers.line.biz/en/reference/messaging-api/#beacon-event

Instance Method Summary collapse

Methods inherited from Base

#[], #initialize, #to_hash

Constructor Details

This class inherits a constructor from Line::Bot::Event::Base

Instance Method Details

#deviceMessageString

Returns:

  • (String)


33
34
35
# File 'lib/line/bot/event/beacon.rb', line 33

def deviceMessage
  [@src['beacon']['dm']].pack('H*')
end

#hwidString

Returns:

  • (String)


28
29
30
# File 'lib/line/bot/event/beacon.rb', line 28

def hwid
  @src['beacon']['hwid']
end

#typeString

Returns:

  • (String)


23
24
25
# File 'lib/line/bot/event/beacon.rb', line 23

def type
  @src['beacon']['type']
end