blob: 9c37d0b0d7964d827a9900e99d88aa9c4c69f980 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
module Mattermost
class Command < Session
def self.create(team_id, trigger: 'gitlab', url:, icon_url:)
post_command(command)['token']
end
private
def post_command(command)
post( "/teams/#{team_id}/commands/create", body: command.to_json).parsed_response
end
end
end
|