Closed
Description
The cards example doesn't work as written. The imports are invalid.
They did work as this:
from webexteamssdk.models.cards.card import AdaptiveCard
from webexteamssdk.models.cards.inputs import Text, Toggle
from webexteamssdk.models.cards.components import TextBlock
from webexteamssdk.models.cards.actions import Submit
Edited to add: I should mention this is a reference to the readthedocs example of cards. The card object import statements do not work as stated in those docs.
$ pip list
Package Version
----------------- ----------
certifi 2020.4.5.1
chardet 3.0.4
click 7.1.1
future 0.18.2
idna 2.9
itsdangerous 1.1.0
Jinja2 2.11.1
MarkupSafe 1.1.1
mcrcon 0.6.0
pip 20.0.2
PyJWT 1.7.1
PyYAML 5.3.1
requests 2.23.0
requests-toolbelt 0.9.1
setuptools 46.1.3
urllib3 1.25.8
webexteamssdk 1.3
Werkzeug 1.0.1
wheel 0.34.2
$ python -V
Python 3.7.3
$ python
Python 3.7.3 (default, Mar 27 2019, 22:11:17)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from webexteamssdk import WebexTeamsAPI
>>> from webexteamssdk.cards.card import AdaptiveCard
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'webexteamssdk.cards'
>>>
Metadata
Metadata
Assignees
Labels
No labels