Skip to content

Commit 24a5b4f

Browse files
authored
Added get_dashboard method (atlassian-api#1109)
* Added request_current_index_from_node method and docs for the cluster methods * Added description to docs for method get_cluster_all_nodes * Added get_dashboard method. Ability to get dashboard by ID. * Fix resource_url for get_dashboard method
1 parent 25170b7 commit 24a5b4f

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

atlassian/jira.py

+10
Original file line numberDiff line numberDiff line change
@@ -649,6 +649,16 @@ def get_dashboards(self, filter="", start=0, limit=10):
649649
url = self.resource_url("dashboard")
650650
return self.get(url, params=params)
651651

652+
def get_dashboard(self, dashboard_id):
653+
"""
654+
Returns a single dashboard
655+
656+
:param dashboard_id: Dashboard ID Int
657+
:return:
658+
"""
659+
url = self.resource_url("dashboard/{dashboard_id}".format(dashboard_id=dashboard_id))
660+
return self.get(url)
661+
652662
"""
653663
Filters. Resource for searches
654664
Reference: https://docs.atlassian.com/software/jira/docs/api/REST/8.5.0/#api/2/filter

docs/jira.rst

+9
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,15 @@ Manage Boards
293293
# Add/Move Issues to sprint
294294
jira.add_issues_to_sprint(sprint_id, issues_list)
295295
296+
297+
Manage dashboards
298+
-----------------
299+
300+
.. code-block:: python
301+
302+
# Get dashboard by ID
303+
jira.get_dashboard(dashboard_id)
304+
296305
Attachments actions
297306
-------------------
298307

0 commit comments

Comments
 (0)