Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed chat_update_message #11

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions pyslack/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,25 +58,23 @@ def chat_post_message(self, channel, text, **params):
})
return self._make_request(method, params)

def chat_update_message(self, channel, text, timestamp, **params):
def chat_update_message(self, channel, text, timestamp):
"""chat.update
https://api.slack.com/methods/chat.update

This method updates a message.

Check docs for all available **params options:
https://api.slack.com/methods/chat.update

Required parameters:
`ts`: Timestamp of the message to be updated (e.g: "1405894322.002768")
`channel`: Channel containing the message to be updated. (e.g: "C1234567890")
`text`: New text for the message, using the default formatting rules. (e.g: "Hello world")
"""
method = 'chat.update'
params.update({
params = {
'channel': channel,
'text': text,
'ts': timestamp,
})
}
return self._make_request(method, params)


Expand Down