37 Micro updates
* Added new methods to the `USER` class and updated the `comment` variable. Now you can be able to post a comment and get a proper comment. The `GET` method has various properties, see the documentation for more details.
* Get a mention of a cloud user.
python
from jiraone import LOGIN, USER
user = "email"
password = "token"
link = "https://yourinstance.atlassian.net"
LOGIN(user=user, password=password, url=link)
if __name__ == '__main__':
the output of the file would be absolute to the directory where this python file is being executed from
displayName of a user, to output multiple users separate by a comma
name = "Prince Nyeche,Prince,John Doe"
name = "Prince Nyeche"
USER.mention_user(name)
* POST a comment to a Jira issue and mention users sequentially on a comment.
python
from jiraone import LOGIN, USER, comment
user = "email"
password = "token"
link = "https://yourinstance.atlassian.net"
LOGIN(user=user, password=password, url=link)
key = "COM-42"
name = "Prince Nyeche,Prince"
text = """
<user> please can you help to check the docker environment? Ping <user> to help out.
"""
comment(key, method="post", text_block=text, placer="<user>", mention=USER.mention_user(name), event=True)
The name of users separated by comma, will be changed dynamically within the method. Using the `event=True` argument enables the comment endpoint to switch to post. See more from the `endpoint` methods. As you can see, for any place in the text string where I used
***< user >*** that will be replaced to a mentioned format for cloud e.g. [~accountId:5584xxxxxx]