2016-12-13 18:52:41 +00:00
|
|
|
module Mattermost
|
2016-12-19 23:22:10 +00:00
|
|
|
class Command < Client
|
|
|
|
def create(params)
|
2017-01-23 11:58:51 +00:00
|
|
|
response = session_post("/api/v3/teams/#{params[:team_id]}/commands/create",
|
2016-12-19 22:53:19 +00:00
|
|
|
body: params.to_json)
|
2016-12-13 18:52:41 +00:00
|
|
|
|
2016-12-19 23:22:10 +00:00
|
|
|
response['token']
|
2016-12-13 18:52:41 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|