Skip to content

Instantly share code, notes, and snippets.

@grokify
Created March 14, 2017 12:37
Show Gist options
  • Save grokify/7ded3b4a3fe020c7d7a3cd6ebe4c36c7 to your computer and use it in GitHub Desktop.
Save grokify/7ded3b4a3fe020c7d7a3cd6ebe4c36c7 to your computer and use it in GitHub Desktop.
Motion AI + Lita + Glip
def message_bot(params = {})
params[:key] = @api_key
params[:bot] = @bot_id
required = [:bot, :msg, :session, :key]
required.each do |param|
unless params.key? param
raise "Required param #{param} not present"
end
end
@http.get URI.join(API_ENDPOINT, MESSAGE_BOT_API_PATH), params
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment