Add support for nested structure, e.g. attachments#100
Add support for nested structure, e.g. attachments#100Yasumoto merged 5 commits intoslackapi:masterfrom greut:nested
Conversation
|
Damn... it took me one week to realize the bugs I've introduced. I was probably too tired to see anything. |
> The optional attachments argument should contain a JSON-encoded array of > attachments. > > https://api.slack.com/methods/chat.postMessage This enables simpler calls like this: sc.api_call('chat.postMessage', {'attachments': [{'title': 'hello'}]})
* `six` is already required by websocket-client so it doesn't add much weight to the overall installation.
|
Any chance of getting this merged in? |
| install_requires=[ | ||
| 'websocket-client', | ||
| 'requests', | ||
| 'six', |
|
This is great! If you also don't mind updating the documentation to ensure other users know this exists, that'd be really helpful. Normally I'd also ask you to add test coverage, but we don't have any good examples quite yet! If you're familiar with responses and don't mind adding test cases that'd be great, otherwise you can skip 'em for this PR and I'll add tests after this gets merged. |
|
@Yasumoto sure, there you go. As of Cheers, |
|
Thanks so much @greut ! |
|
@Yasumoto my pleasure. Congrats on your new job at SlackHQ. |
Add support for nested structure, e.g. attachments
This enables simpler calls like this: