2017-07-13 08:32:11 -04:00
|
|
|
require_dependency 'admin_constraint'
|
|
|
|
|
|
|
|
module DiscourseChat
|
|
|
|
AdminEngine.routes.draw do
|
|
|
|
get "" => "chat#respond"
|
|
|
|
get '/providers' => "chat#list_providers"
|
2017-07-18 11:17:03 -04:00
|
|
|
post '/test' => "chat#test"
|
2017-07-13 08:32:11 -04:00
|
|
|
|
2017-07-18 11:17:03 -04:00
|
|
|
get '/channels' => "chat#list_channels"
|
|
|
|
post '/channels' => "chat#create_channel"
|
|
|
|
put '/channels/:id' => "chat#update_channel"
|
|
|
|
delete '/channels/:id' => "chat#destroy_channel"
|
|
|
|
|
|
|
|
post '/rules' => "chat#create_rule"
|
2017-07-13 08:32:11 -04:00
|
|
|
put '/rules/:id' => "chat#update_rule"
|
|
|
|
delete '/rules/:id' => "chat#destroy_rule"
|
|
|
|
|
|
|
|
get "/:provider" => "chat#respond"
|
|
|
|
end
|
2017-07-24 11:13:53 -04:00
|
|
|
|
|
|
|
PublicEngine.routes.draw do
|
|
|
|
get '/:secret' => "public#post_transcript"
|
|
|
|
end
|
2017-07-13 08:32:11 -04:00
|
|
|
end
|