Class: Hg::Assistant::FulfillmentController

Inherits:
ApplicationController show all
Defined in:
app/controllers/hg/assistant/fulfillment_controller.rb

Instance Method Summary collapse

Instance Method Details

#fulfillObject

Handle API.ai fulfillment requests.



10
11
12
13
14
15
16
# File 'app/controllers/hg/assistant/fulfillment_controller.rb', line 10

def fulfill
  fulfillment_response = bot.router.handle(bot_request)

  logger.info fulfillment_response.inspect if Rails.env.development?

  render json: fulfillment_response.to_json
end