Skip to content

Commit 7a64fe0

Browse files
author
Brad Haas
committed
add support for adaptive card message create
1 parent b9ac306 commit 7a64fe0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

webexteamssdk/api/messages.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ def list(self, roomId, mentionedPeople=None, before=None,
135135
yield self._object_factory(OBJECT_TYPE, item)
136136

137137
def create(self, roomId=None, toPersonId=None, toPersonEmail=None,
138-
text=None, markdown=None, files=None, **request_parameters):
138+
text=None, markdown=None, files=None, attachments=None, **request_parameters):
139139
"""Post a message, and optionally a attachment, to a room.
140140
141141
The files parameter is a list, which accepts multiple values to allow
@@ -174,6 +174,7 @@ def create(self, roomId=None, toPersonId=None, toPersonEmail=None,
174174
check_type(text, basestring)
175175
check_type(markdown, basestring)
176176
check_type(files, list)
177+
check_type(attachments, list)
177178
if files:
178179
if len(files) != 1:
179180
raise ValueError("The length of the `files` list is greater "
@@ -192,6 +193,7 @@ def create(self, roomId=None, toPersonId=None, toPersonEmail=None,
192193
text=text,
193194
markdown=markdown,
194195
files=files,
196+
attachments=attachments,
195197
)
196198

197199
# API request

0 commit comments

Comments
 (0)