Skip to content

API Reference parrot_tools.jiratoolkit

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot_tools.jiratoolkit

View source

Jira Toolkit - A unified toolkit for Jira operations using pycontribs/jira.

This toolkit wraps common Jira actions as async tools, extending AbstractToolkit. It supports multiple authentication modes on init: basic_auth, token_auth, and OAuth1.

Notes:

  • All public async methods become tools via AbstractToolkit.
  • Methods are async but the underlying jira client is sync, so calls run via asyncio.to_thread.
  • Each method returns JSON-serializable dicts/lists (using Issue.raw where possible).

Class AddAttachmentInput

Input for adding an attachment to an issue.

Fields:

Field Type Default Description
issue str Issue key or id
file_ids List[str] Session file handles to attach, from sf_list_session_files. Filesystem paths and URLs are not accepted.

Class AddCommentInput

Input for adding a comment to an issue.

Fields:

Field Type Default Description
issue str Issue key or id
body Optional[str] None Comment body text (required unless a template applies)
is_internal bool False If true, mark as internal (Service Desk)
file_ids Optional[List[str]] None Optional session file handles to attach to the issue alongside this comment, from sf_list_session_files. Files are attached at the issue level. Filesystem paths and URLs are not accepted.
template Optional[str] None Template name used to compose the text (e.g. 'nav/bug' or 'nav/bug.j2'); see jira_list_templates. Omit to apply the configured convention template, if any.
template_params Optional[Dict[str, Any]] None Extra variables available to the template; they override same-named call fields.

Class AddComponentInput

Input for adding a component to an issue by name.

Fields:

Field Type Default Description
issue str Issue key or id (e.g. 'NAV-6213')
component_name str Component name (case-insensitive, e.g. 'Backend')
project Optional[str] None Project key. Falls back to default project if omitted.

Class AddWatcherInput

Input for adding a watcher to an issue.

Fields:

Field Type Default Description
issue str Issue key or id (e.g. 'NAV-6213')
email str Email address of the user to add as watcher

Class AddWorklogInput

Input for adding a worklog to an issue.

Fields:

Field Type Default Description
issue str Issue key or id
time_spent str Time spent, e.g. '2h', '30m'
comment Optional[str] None Worklog comment
started Optional[str] None Date started (ISO-8601 or similar)

Class AssignIssueInput

Input for assigning an issue to a user.

Fields:

Field Type Default Description
issue str Issue key or id
assignee str Account id or username (depends on Jira cloud/server)

Class ChangeAssigneeInput

Input for changing assignee.

Fields:

Field Type Default Description
issue str Issue key or id
assignee str New assignee (account ID or username)

Class ChangeReporterInput

Input for changing the reporter of an issue.

Fields:

Field Type Default Description
issue str Issue key or id (e.g. 'NAV-6213')
email str Email address of the new reporter

Class ConfigureClientInput

Input for re-configuring the Jira client.

Fields:

Field Type Default Description
username Optional[str] None New username (email)
password Optional[str] None New password or API token
token Optional[str] None New Personal Access Token
auth_type Optional[str] None Authentication type: 'basic_auth', 'token_auth', etc.
server_url Optional[str] None New server URL

Class CountIssuesInput

Optimized input for counting issues - requests minimal fields.

Fields:

Field Type Default Description
jql str JQL query to count issues
group_by Optional[List[str]] None Fields to group counts by. Options: 'assignee', 'reporter', 'status', 'priority', 'issuetype', 'project'. Example: ['assignee', 'status'] for count by user and status.

Class CreateIssueInput

Input for creating a new issue.

Fields:

Field Type Default Description
project str 'NAV' Project key, e.g. 'NAV' or project id
summary str Issue summary/title
issuetype str 'Task' Issue type, e.g. 'Task', 'Story', 'Bug', 'Epic', 'Sub-task'
description Optional[str] None Issue description
assignee Optional[str] None Assignee account ID or username
priority Optional[Literal['Highest', 'High', 'Medium', 'Low', 'Lowest']] None Priority
labels Optional[List[str]] None Labels list, e.g. ['backend', 'urgent']
components Optional[List[str]] None List of component IDs (not names). Use jira_get_components(project) to find IDs first.
due_date Optional[str] None Due date in YYYY-MM-DD format
parent Optional[str] None Parent issue key for sub-tasks or stories under epics
original_estimate Optional[str] None Original time estimate, e.g. '8h', '2d', '30m'
fields Optional[Dict[str, Any]] None Additional fields dict for custom or less common fields
template Optional[str] None Template name used to compose the text (e.g. 'nav/bug' or 'nav/bug.j2'); see jira_list_templates. Omit to apply the configured convention template, if any.
template_params Optional[Dict[str, Any]] None Extra variables available to the template; they override same-named call fields.

Class FindIssuesByAssigneeInput

Input for finding issues assigned to a given user.

Fields:

Field Type Default Description
assignee str Assignee identifier (e.g., 'admin' or accountId)
project Optional[str] None Restrict to project key
max_results int 50 Max results

Class FindUserInput

Input for finding a user.

Fields:

Field Type Default Description
email str User email address or query string

Class GetIssueInput

Input for getting a single issue.

Fields:

Field Type Default Description
issue str Issue key or id, e.g., 'JRA-1330'
fields Optional[str] None Fields to fetch (comma-separated) or '*'
expand Optional[str] None Entities to expand, e.g. 'renderedFields'
include_history bool False Include the issue history
history_page_size Optional[int] 100 number of items to be returned via changelog
structured Optional[StructuredOutputOptions] None Optional structured output mapping

Class GetIssueTypesInput

Input for listing issue types.

Fields:

Field Type Default Description
project Optional[str] None Project key to filter by. If omitted, returns all available types.

Class GetProjectsInput

Input for listing projects.

Class GetTransitionsInput

Input for getting available transitions for an issue.

Fields:

Field Type Default Description
issue str Issue key or id
expand Optional[str] None Expand options, e.g. 'transitions.fields'

Class JiraInput

Default input for Jira tools: holds auth + default project context.

You usually do not pass this into every call; it's used to configure the toolkit on initialization. It's defined here for consistency and as a type you can reuse when wiring the toolkit into agents.

Fields:

Field Type Default Description
server_url str Base URL for Jira server (e.g., https://your.atlassian.net)
auth_type str 'token_auth' Authentication type: 'basic_auth', 'token_auth', or 'oauth'
username Optional[str] None Username (email) for basic/token auth
password Optional[str] None Password for basic auth (or API token)
token Optional[str] None Personal Access Token for token_auth
oauth_consumer_key Optional[str] None
oauth_key_cert Optional[str] None PEM private key content or path
oauth_access_token Optional[str] None
oauth_access_token_secret Optional[str] None
default_project Optional[str] None Default project key, e.g., 'JRA'

Class JiraToolkit

Toolkit for interacting with Jira via pycontribs/jira.

Provides methods for:

  • Getting an issue
  • Searching issues
  • Transitioning issues
  • Adding attachments
  • Assigning issues
  • Creating and updating issues
  • Finding issues by assignee
  • Counting issues
  • Aggregating stored Jira data

Recognized config/env keys: JIRA_SERVER_URL, JIRA_AUTH_TYPE, JIRA_USERNAME, JIRA_PASSWORD, JIRA_TOKEN, JIRA_OAUTH_CONSUMER_KEY, JIRA_OAUTH_KEY_CERT, JIRA_OAUTH_ACCESS_TOKEN, JIRA_OAUTH_ACCESS_TOKEN_SECRET, JIRA_DEFAULT_PROJECT, JIRA_TEMPLATES_DIR

Custom-workflow keys (used by :meth:jira_transition_to): JIRA_WORKFLOW_PATH — default ordered status chain for any project, e.g. "Backlog > Open > To Do > In Progress > Resolved" (>, -> and → are all accepted separators). JIRA_WORKFLOW_PATH_ — per-project override keyed by the issue key prefix, e.g. JIRA_WORKFLOW_PATH_TROC. Falls back to JIRA_WORKFLOW_PATH when a project has no specific entry.

Usage:

For counts - efficient, minimal context

jira.jira_count_issues( jql="project = NAV AND status = Open", group_by=["assignee", "status"] )

For analysis - store in DataFrame

jira.jira_search_issues( jql="project = NAV", max_results=1000, fields="key,assignee,status,created", # Only what you need! store_as_dataframe=True, summary_only=True # Just counts in response )

Parameter Type Default Description
server_url Optional[str] None
auth_type Optional[str] None
username Optional[str] None
password Optional[str] None
token Optional[str] None
oauth_consumer_key Optional[str] None
oauth_key_cert Optional[str] None
oauth_access_token Optional[str] None
oauth_access_token_secret Optional[str] None
default_project Optional[str] None
credential_resolver Any None
workflow_paths Optional[Dict[str, Union[str, List[str]]]] None
verify_credentials bool True
templates_dir Optional[Union[str, Path]] None
templates Optional[Mapping[str, str]] None
knowledge_base Optional[Union[str, Path, JiraKnowledgeBase]] None
**kwargs {}

Attributes:

Attribute Type Description
request_timeout float
templates_dir Optional[Path]
workflow_paths Dict[str, List[str]]
jira Any The Jira client for the current call. In oauth2_3lo mode _pre_execute binds the calling principal's client to the current asyncio context, so two principals interleaving on one toolkit instance can never see each other's client. Static modes use the single client set at init.
site_url str Browser-facing Jira site URL (e.g. https://acme.atlassian.net). Differs from :attr:server_url when API calls go through the Atlassian gateway (service-account scoped tokens, OAuth 2.0 3LO): the site is then read once from serverInfo and cached. Set site_url= / JIRA_SITE_URL to skip that lookup. Empty string when no URL is known.

Method JiraToolkit.config_options

Dynamic choices for Agent Studio (FEAT-593): project keys for default_project.

config_options(param: str) -> list[ConfigOption]

Parameter Type Default Description
param str

Returns: list[ConfigOption]

Method JiraToolkit.set_tool_manager

Set the ToolManager reference for DataFrame sharing.

set_tool_manager(manager: ToolManager)

Parameter Type Default Description
manager ToolManager

Method JiraToolkit.browse_url

<site_url>/browse/<key>, or "" when either is unknown.

browse_url(key: Optional[str]) -> str

Parameter Type Default Description
key Optional[str]

Returns: str

Method JiraToolkit.jira_get_issue

Get a Jira issue by key or id.

Returns a :class:JiraToolEnvelope with status="ok" on success, status="not_found" when the issue key does not exist (HTTP 404), or status="error" for other recoverable failures. Authentication and permission errors are re-raised rather than wrapped.

Example: issue = jira.issue('JRA-1330')

If structured is provided, the output will be transformed according to the options.

jira_get_issue(issue: str, fields: Optional[str] = None, expand: Optional[str] = None, structured: Optional[StructuredOutputOptions] = None, include_history: bool = False, history_page_size: int = 100) -> JiraToolEnvelope

Parameter Type Default Description
issue str
fields Optional[str] None
expand Optional[str] None
structured Optional[StructuredOutputOptions] None
include_history bool False
history_page_size int 100

Returns: JiraToolEnvelope

Method JiraToolkit.jira_transition_issue

Transition a Jira issue. Requires jira.write permission.

Automatically sets 8h original estimate for issues without one when transitioning to 'To Do', 'TODO', or 'In Progress'.

The transition argument accepts a transition id (e.g. '5'), a transition action name (e.g. 'Start Progress'), or a target status name (e.g. 'Done'). The available transitions depend on the project's workflow — if the requested value cannot be resolved, this tool raises an error listing every valid option so you can retry with a correct one.

jira_transition_issue(issue: str, transition: Union[str, int], fields: Optional[Dict[str, Any]] = None, assignee: Optional[Dict[str, Any]] = None, resolution: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
transition Union[str, int]
fields Optional[Dict[str, Any]] None
assignee Optional[Dict[str, Any]] None
resolution Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_transition_to

Move an issue to target_status, walking every intermediate step.

Jira only exposes the transitions available from an issue's current status, so a single transition cannot cross a multi-stage workflow (e.g. Backlog → Open → To Do → In Progress → Resolved). This tool consults the project's declared workflow path (configured via JIRA_WORKFLOW_PATH / JIRA_WORKFLOW_PATH_<PROJECT> or the workflow_paths constructor arg) and applies each hop in turn until the issue reaches target_status. fields/assignee/resolution are applied only on the FINAL hop.

When no workflow path is declared (or the endpoints are not on it), it falls back to a single direct transition — identical to :meth:jira_transition_issue.

Requires jira.write permission.

jira_transition_to(issue: str, target_status: str, fields: Optional[Dict[str, Any]] = None, assignee: Optional[Dict[str, Any]] = None, resolution: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
target_status str
fields Optional[Dict[str, Any]] None
assignee Optional[Dict[str, Any]] None
resolution Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_add_attachment

Attach one or more session files to an issue. Requires jira.write permission.

file_ids come from sf_list_session_files. Returns a report with one entry per handle; a per-file failure is reported, never raised — read attachments[].error_code.

Example: jira_add_attachment(issue='NAV-123', file_ids=['Ab3...'])

jira_add_attachment(issue: str, file_ids: List[str]) -> Dict[str, Any]

Parameter Type Default Description
issue str
file_ids List[str]

Returns: Dict[str, Any]

Method JiraToolkit.jira_assign_issue

Assign an issue to a user. Requires jira.write permission.

Accepts an email address or an accountId.

jira_assign_issue(issue: str, assignee: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
assignee str

Returns: Dict[str, Any]

Method JiraToolkit.jira_create_issue

Create a new issue. Requires jira.write permission.

Omitted fields fall back to configured defaults (JIRA_DEFAULT_* env vars).

Assignee accepts an email address or accountId — emails are resolved automatically. Components accept names or IDs — names are resolved automatically.

jira_create_issue(project: Optional[str] = None, summary: str = '', issuetype: Optional[str] = None, description: Optional[str] = None, assignee: Optional[str] = None, priority: Optional[str] = None, labels: Optional[List[str]] = None, components: Optional[List[str]] = None, due_date: Optional[str] = None, parent: Optional[str] = None, original_estimate: Optional[str] = None, fields: Optional[Dict[str, Any]] = None, template: Optional[str] = None, template_params: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
project Optional[str] None
summary str ''
issuetype Optional[str] None
description Optional[str] None
assignee Optional[str] None
priority Optional[str] None
labels Optional[List[str]] None
components Optional[List[str]] None
due_date Optional[str] None
parent Optional[str] None
original_estimate Optional[str] None
fields Optional[Dict[str, Any]] None
template Optional[str] None
template_params Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_update_issue

Update an existing issue. Requires jira.write permission.

jira_update_issue(issue: str, summary: Optional[str] = None, description: Optional[str] = None, assignee: Optional[Dict[str, Any]] = None, acceptance_criteria: Optional[str] = None, original_estimate: Optional[str] = None, time_tracking: Optional[Dict[str, str]] = None, affected_versions: Optional[List[Dict[str, str]]] = None, due_date: Optional[str] = None, labels: Optional[List[str]] = None, issuetype: Optional[Dict[str, str]] = None, priority: Optional[Dict[str, str]] = None, fields: Optional[Dict[str, Any]] = None, template: Optional[str] = None, template_params: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
summary Optional[str] None
description Optional[str] None
assignee Optional[Dict[str, Any]] None
acceptance_criteria Optional[str] None
original_estimate Optional[str] None
time_tracking Optional[Dict[str, str]] None
affected_versions Optional[List[Dict[str, str]]] None
due_date Optional[str] None
labels Optional[List[str]] None
issuetype Optional[Dict[str, str]] None
priority Optional[Dict[str, str]] None
fields Optional[Dict[str, Any]] None
template Optional[str] None
template_params Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_find_issues_by_assignee

Find issues assigned to a given user (thin wrapper over jira_search_issues).

Example: jira.search_issues("assignee=admin")

jira_find_issues_by_assignee(assignee: str, project: Optional[str] = None, max_results: int = 50) -> Dict[str, Any]

Parameter Type Default Description
assignee str
project Optional[str] None
max_results int 50

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_transitions

Get available transitions for an issue.

Example: jira.jira_get_transitions('JRA-1330')

jira_get_transitions(issue: str, expand: Optional[str] = None) -> List[Dict[str, Any]]

Parameter Type Default Description
issue str
expand Optional[str] None

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_add_comment

Add a comment to an issue, optionally attaching files. Requires jira.write permission.

Set is_internal=True to post an internal (agent-only) comment on a Jira Service Management issue; by default the comment is public.

Example: jira.jira_add_comment('JRA-1330', 'This is a comment') Example internal (Service Desk): jira.jira_add_comment('SD-42', 'Agent note', is_internal=True) Example with attachments: jira.jira_add_comment( 'JRA-1330', 'See attached screenshot', file_ids=['Ab3xYz...'] )

jira_add_comment(issue: str, body: Optional[str] = None, is_internal: bool = False, file_ids: Optional[List[str]] = None, template: Optional[str] = None, template_params: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
body Optional[str] None
is_internal bool False
file_ids Optional[List[str]] None
template Optional[str] None
template_params Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_add_worklog

Add worklog to an issue. Requires jira.write permission.

Example: jira.jira_add_worklog('JRA-1330', '1h 30m', 'Working on feature')

jira_add_worklog(issue: str, time_spent: str, comment: Optional[str] = None, started: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
time_spent str
comment Optional[str] None
started Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_issue_types

List issue types, optionally for a specific project.

Example: jira.jira_get_issue_types(project='PROJ')

jira_get_issue_types(project: Optional[str] = None) -> List[Dict[str, Any]]

Parameter Type Default Description
project Optional[str] None

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_list_templates

List the Jira text templates usable with jira_create_issue, jira_update_issue and jira_add_comment.

Pass a returned name as template= to a write tool. Without template= the write tools apply a convention template automatically when one exists: <project>/<issuetype>.j2 → <project>/_default.j2 → _default.j2 for issues, <project>/comment.j2 → comment.j2 for comments.

jira_list_templates(project: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
project Optional[str] None

Returns: Dict[str, Any] — {"ok": True, "templates": [names], "has_templates_dir": bool} — logical names only; the filesystem location is never exposed.

Method JiraToolkit.jira_get_projects

List all accessible projects.

On Jira Cloud, a silently failed authentication (wrong username or revoked API token) returns an empty project list with HTTP 200 and a X-Seraph-Loginreason: AUTHENTICATED_FAILED header. When the list comes back empty this tool probes /rest/api/2/myself; if the probe confirms the session is not authenticated it raises :class:AuthorizationRequired (surfaced by ToolManager as a structured authorization_required ToolResult) instead of returning an empty-but-successful payload.

Returns: {"projects": [...], "count": N, "authenticated": True, "hint": ...}

jira_get_projects() -> Dict[str, Any]

Returns: Dict[str, Any]

Raises:

  • AuthorizationRequired — When the empty list is caused by failed authentication (expired/revoked token, wrong username).

Method JiraToolkit.jira_verify_auth

Verify the toolkit is authenticated against Jira.

Performs a raw GET /rest/api/2/myself so the Atlassian X-Seraph-Loginreason header is inspected — this catches the silent-auth-failure case where the API still returns HTTP 200 but serves anonymous content. Never raises.

jira_verify_auth() -> Dict[str, Any]

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_components

List all components for a project. Use this to find component IDs before creating issues.

IMPORTANT: When creating issues with components, you must use the component ID (not the name). Call this method first to discover the IDs.

Example: jira.jira_get_components(project='NAV') Returns: [{"id": "10042", "name": "Backend", "description": "..."}, ...]

jira_get_components(project: Optional[str] = None) -> List[Dict[str, Any]]

Parameter Type Default Description
project Optional[str] None

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_get_component_by_name

Find a component by name and return its details including the internal ID.

Use this method to resolve a component name to its Jira internal ID before creating tickets. Jira requires component IDs (not names) when creating or updating issues.

jira_get_component_by_name(name: str, project: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
name str Component name to search for (case-insensitive match).
project Optional[str] None Project key. Falls back to default project if omitted.

Returns: Dict[str, Any] — Dict with keys: id, name, description.

Raises:

  • ValueError — If the component name is not found in the project.

Method JiraToolkit.jira_search_users

Search for users matching the specified search string.

Returns a :class:JiraToolEnvelope with status="ok" when users are found, status="empty" when the search returns no results, or status="error" for recoverable failures. Authentication errors are re-raised.

"username" query parameter is deprecated in Jira Cloud; the expected parameter now is "query". But the "user" parameter is kept for backwards compatibility.

jira_search_users(user: Optional[str] = None, start_at: int = 0, max_results: int = 50, include_active: bool = True, include_inactive: bool = False, query: Optional[str] = None) -> JiraToolEnvelope

Parameter Type Default Description
user Optional[str] None
start_at int 0
max_results int 50
include_active bool True
include_inactive bool False
query Optional[str] None

Returns: JiraToolEnvelope

Method JiraToolkit.jira_search_issues

Search issues with JQL.

Returns a :class:JiraToolEnvelope. status="ok" carries the legacy success payload inside data; status="empty" means zero results; status="error" wraps a recoverable failure. Authentication errors are re-raised.

For efficiency:

  • Use fields to request only needed data (e.g., 'key,assignee,status')
  • Use max_results=None to fetch all matching issues
  • Use summary_only=True for counts to avoid context bloat
  • Use store_as_dataframe=True for complex analysis with PythonPandasTool

Examples:

Simple search (default)

jira_search_issues(jql="project = NAV AND status = Open")

Fetch all issues for counting

jira_search_issues( jql="project = NAV AND status = Open", max_results=None, # Fetch all! fields="key,assignee,status", summary_only=True )

Full data for analysis

jira_search_issues( jql="project = NAV", max_results=None, fields="key,summary,assignee,status,created,priority", store_as_dataframe=True, dataframe_name="nav_issues" )

Then use PythonPandasTool to analyze 'nav_issues' DataFrame

jira_search_issues(jql: str, start_at: int = 0, max_results: Optional[int] = 100, fields: Optional[str] = None, expand: Optional[str] = None, json_result: bool = True, store_as_dataframe: bool = False, dataframe_name: Optional[str] = None, summary_only: bool = False, structured: Optional[StructuredOutputOptions] = None) -> JiraToolEnvelope

Parameter Type Default Description
jql str
start_at int 0
max_results Optional[int] 100
fields Optional[str] None
expand Optional[str] None
json_result bool True
store_as_dataframe bool False
dataframe_name Optional[str] None
summary_only bool False
structured Optional[StructuredOutputOptions] None

Returns: JiraToolEnvelope

Method JiraToolkit.jira_count_issues

Count issues with optional grouping - optimized for efficiency.

Uses minimal fields to reduce payload size and processing time. Fetches ALL matching issues to provide accurate counts.

Examples:

Total count

jira_count_issues(jql="project = NAV AND status = Open")

Returns: {"total_count": 847, "fetched_count": 847}

Count by assignee

jira_count_issues( jql="project = NAV AND created >= '2025-01-01'", group_by=["assignee"] )

Returns: {"total_count": 234, "by_assignee": {"John": 45, "Jane": 32, ...}}

Count by multiple fields

jira_count_issues( jql="project = NAV", group_by=["assignee", "status"] )

jira_count_issues(jql: str, group_by: Optional[List[str]] = None) -> Dict[str, Any]

Parameter Type Default Description
jql str
group_by Optional[List[str]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_my_tickets

Retrieve the tickets assigned to the CURRENT (authenticated) Jira user.

INSTRUCT: Run this tool whenever the user asks for HIS/HER own tickets or issues. Example trigger phrases (English and Spanish): "my tickets", "my issues", "my open tickets", "what am I assigned to", "tickets assigned to me", "show me my work", "what's on my plate", "mis tickets", "mis issues", "mis tareas asignadas", "qué tengo asignado". In those cases, do NOT build a JQL query manually and do NOT call jira_search_issues — use this tool instead. It resolves the authenticated identity server-side via the JQL currentUser() function, so it always returns tickets assigned to the user who owns the active OAuth token (no email lookups, no PII, no name-collision ambiguity).

When status is omitted, Done/Closed/Resolved tickets are filtered out so the response focuses on actionable work. Pass include_closed=True to include them.

Examples:

All my active tickets (excludes Done/Closed/Resolved)

await jira_get_my_tickets()

My in-progress NAV tickets

await jira_get_my_tickets(status="In Progress", project="NAV")

Everything assigned to me, including closed work

await jira_get_my_tickets(include_closed=True, max_results=None)

jira_get_my_tickets(status: Optional[Union[str, List[str]]] = None, project: Optional[str] = None, include_closed: bool = False, max_results: Optional[int] = 50, order_by: Optional[str] = 'updated DESC', fields: Optional[str] = 'key,summary,status,priority,issuetype,project,created,updated,duedate', summary_only: bool = False) -> Dict[str, Any]

Parameter Type Default Description
status Optional[Union[str, List[str]]] None Optional status filter. A single status ("In Progress") or a list (["To Do", "In Progress"]).
project Optional[str] None Optional Jira project key filter (e.g. "NAV").
include_closed bool False When True, include Done/Closed/Resolved tickets. Ignored when status is provided.
max_results Optional[int] 50 Max tickets to return. Use None to fetch all.
order_by Optional[str] 'updated DESC' JQL ORDER BY clause. Default: "updated DESC".
fields Optional[str] 'key,summary,status,priority,issuetype,project,created,updated,duedate' Comma-separated Jira fields to return.
summary_only bool False Return grouped counts instead of raw tickets.

Returns: Dict[str, Any] — Dict with the matching issues (or a grouped summary when summary_only=True).

Method JiraToolkit.jira_aggregate_data

Aggregate data from a stored Jira DataFrame.

Use this after jira_search_issues with fetch_all=True to perform custom aggregations on the stored data.

Examples:

Count by assignee

jira_aggregate_data( dataframe_name="jira_issues", group_by=["assignee_name"], aggregations={"key": "count"} )

Sum story points by status

jira_aggregate_data( dataframe_name="jira_issues", group_by=["status"], aggregations={"story_points": "sum", "key": "count"}, sort_by="story_points" )

jira_aggregate_data(dataframe_name: str = 'jira_issues', group_by: List[str] = None, aggregations: Dict[str, str] = None, sort_by: Optional[str] = None, ascending: bool = False) -> Dict[str, Any]

Parameter Type Default Description
dataframe_name str 'jira_issues'
group_by List[str] None
aggregations Dict[str, str] None
sort_by Optional[str] None
ascending bool False

Returns: Dict[str, Any]

Method JiraToolkit.jira_set_assignee

Set the assignee of an issue by email or accountId.

Resolves the email to an accountId automatically when needed.

jira_set_assignee(issue: str, assignee: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
assignee str

Returns: Dict[str, Any]

Method JiraToolkit.jira_set_reporter

Change the reporter of an issue by email.

Resolves the email to an accountId, then updates the reporter field.

jira_set_reporter(issue: str, email: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
email str

Returns: Dict[str, Any]

Method JiraToolkit.jira_add_component

Add a component to an issue by name.

Resolves the component name to its internal Jira ID, then appends it to the issue's existing components (without removing current ones).

jira_add_component(issue: str, component_name: str, project: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
component_name str
project Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_add_watcher

Add a user to an issue's watchers list ("who's looking").

Resolves the email to an accountId, then adds them as a watcher.

jira_add_watcher(issue: str, email: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
email str

Returns: Dict[str, Any]

Method JiraToolkit.jira_set_acceptance_criteria

Set the acceptance criteria checklist on an issue.

Formats the criteria as a numbered markdown list and writes it to the acceptance-criteria custom field. If custom_field is not provided, the method auto-detects by trying common custom field IDs (customfield_10021, customfield_10022, customfield_10035).

jira_set_acceptance_criteria(issue: str, criteria: List[str], custom_field: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
criteria List[str]
custom_field Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_configure_client

Re-configure the Jira client with new credentials. Requires jira.admin permission.

Updates the internal client instance to use the provided credentials. Useful for switching users or rotating tokens without restarting the agent.

jira_configure_client(username: Optional[str] = None, password: Optional[str] = None, token: Optional[str] = None, auth_type: Optional[str] = None, server_url: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
username Optional[str] None
password Optional[str] None
token Optional[str] None
auth_type Optional[str] None
server_url Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_list_transitions

List all status changes (transitions) for a ticket.

jira_list_transitions(issue: str) -> List[Dict[str, Any]]

Parameter Type Default Description
issue str

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_create_issue_link

Link two issues (e.g. 'Blocks', 'Relates'). Use jira_get_link_types for valid names.

jira_create_issue_link(inward_issue: str, outward_issue: str, link_type: str = 'Relates', comment: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
inward_issue str
outward_issue str
link_type str 'Relates'
comment Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_link_types

List issue link types: name, inward and outward descriptions.

jira_get_link_types() -> List[Dict[str, Any]]

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_get_create_fields

Fields (id, name, required, schema, allowedValues) to create an issue of this type.

jira_get_create_fields(issue_type: str, project: Optional[str] = None) -> Dict[str, Any]

Parameter Type Default Description
issue_type str
project Optional[str] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_edit_comment

Replace the body of an existing comment.

jira_edit_comment(issue: str, comment_id: str, body: Optional[str] = None, template: Optional[str] = None, template_params: Optional[Dict[str, Any]] = None) -> Dict[str, Any]

Parameter Type Default Description
issue str
comment_id str
body Optional[str] None
template Optional[str] None
template_params Optional[Dict[str, Any]] None

Returns: Dict[str, Any]

Method JiraToolkit.jira_get_accessible_resources

Return {cloud_id, site_url, sites, source} in any auth mode.

jira_get_accessible_resources() -> Dict[str, Any]

Returns: Dict[str, Any]

Method JiraToolkit.jira_list_assignees

List all historical assignees of a ticket.

jira_list_assignees(issue: str) -> List[Dict[str, Any]]

Parameter Type Default Description
issue str

Returns: List[Dict[str, Any]]

Method JiraToolkit.jira_update_ticket

Update a ticket (alias for jira_update_issue). Requires jira.write permission.

jira_update_ticket(**kwargs) -> Dict[str, Any]

Parameter Type Default Description
**kwargs {}

Returns: Dict[str, Any]

Method JiraToolkit.jira_change_assignee

Change the ticket to a new assignee. Requires jira.write permission.

jira_change_assignee(issue: str, assignee: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
assignee str

Returns: Dict[str, Any]

Method JiraToolkit.jira_find_user

Find a user by email.

jira_find_user(email: str) -> Dict[str, Any]

Parameter Type Default Description
email str

Returns: Dict[str, Any]

Method JiraToolkit.jira_list_tags

List all tags (labels) added to a ticket.

jira_list_tags(issue: str) -> List[str]

Parameter Type Default Description
issue str

Returns: List[str]

Method JiraToolkit.jira_add_tag

Add a tag to a ticket. Requires jira.write permission.

jira_add_tag(issue: str, tag: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
tag str

Returns: Dict[str, Any]

Method JiraToolkit.jira_remove_tag

Remove a tag from a ticket. Requires jira.write permission.

jira_remove_tag(issue: str, tag: str) -> Dict[str, Any]

Parameter Type Default Description
issue str
tag str

Returns: Dict[str, Any]

Class ListHistoryInput

Input for listing history.

Fields:

Field Type Default Description
issue str Issue key or id

Class SearchIssuesInput

Input for searching issues with JQL.

Fields:

Field Type Default Description
jql str JQL query. Must include at least one filter clause (e.g. 'project = PROJ', 'assignee = currentUser()', a date range). Jira Cloud rejects unbounded queries like 'order by created desc' with no restriction.
start_at int 0 Start index for pagination
max_results Optional[int] 100 Max results to return. Set to None to fetch all matching issues. Jira supports up to 1000 per page. Default 100 is for browsing; use None for complete counts.
fields Optional[str] None Fields to return (comma-separated). Use minimal fields for efficiency: 'key,assignee,status,priority' for counts, 'key,summary,assignee,status,created' for listings, '*all' or None for full details. Fewer fields = faster response and smaller context.
expand Optional[str] None Expand options (changelog, renderedFields, etc.)
structured Optional[StructuredOutputOptions] None Optional structured output mapping
json_result bool True Return results as a JSON object instead of a list of issues. Set True when you need to do aggregations, grouping, or complex analysis.
store_as_dataframe bool False Store results in a shared DataFrame for analysis with PythonPandasTool. Set True when you need to do aggregations, grouping, or complex analysis.
dataframe_name Optional[str] None Name for the stored DataFrame. Defaults to 'jira_issues'.
summary_only bool False Return only summary statistics (counts by assignee, status, etc.) instead of raw issues. Ideal for 'how many' or 'count by' queries. Drastically reduces context window usage.

Class SetAcceptanceCriteriaInput

Input for setting acceptance criteria on an issue.

Fields:

Field Type Default Description
issue str Issue key or id (e.g. 'NAV-6213')
criteria List[str] List of acceptance criteria items (each item becomes a checklist entry)
custom_field Optional[str] None Custom field ID for acceptance criteria (e.g. 'customfield_10021'). Auto-detected if omitted.

Class TagInput

Input for tag operations.

Fields:

Field Type Default Description
issue str Issue key or id
tag str Tag (label) name

Class TicketIdInput

Input for generic ticket operations.

Fields:

Field Type Default Description
issue str Issue key or id

Class TransitionIssueInput

Input for transitioning an issue.

Fields:

Field Type Default Description
issue str Issue key or id
transition Union[str, int] Transition id or name (e.g., '5' or 'Done')
fields Optional[Dict[str, Any]] None Extra fields to set on transition
assignee Optional[Dict[str, Any]] None Assignee dict, e.g., {'name': 'pm_user'}
resolution Optional[Dict[str, Any]] None Resolution dict, e.g., {'id': '3'}

Class UpdateIssueInput

Input for updating an existing issue.

Fields:

Field Type Default Description
issue str Issue key or id
summary Optional[str] None New summary
description Optional[str] None New description
assignee Optional[Dict[str, Any]] None New assignee dict, e.g. {'accountId': '...'}
acceptance_criteria Optional[str] None Acceptance criteria text (often stored in a custom field)
original_estimate Optional[str] None Original time estimate, e.g. '2h', '1d', '30m'
time_tracking Optional[Dict[str, str]] None Time tracking dict, e.g. {'originalEstimate': '2h', 'remainingEstimate': '1h'}
affected_versions Optional[List[Dict[str, str]]] None Affected versions list, e.g. [{'name': '1.0'}, {'name': '2.0'}]
due_date Optional[str] None Due date in YYYY-MM-DD format
labels Optional[List[str]] None Labels list, e.g. ['backend', 'priority']
issuetype Optional[Dict[str, str]] None Issue type dict, e.g. {'name': 'Bug'} or {'id': '10001'}
priority Optional[Dict[str, str]] None Priority dict, e.g. {'name': 'High'} or {'id': '2'}
fields Optional[Dict[str, Any]] None Arbitrary field updates dict
template Optional[str] None Template name used to compose the text (e.g. 'nav/bug' or 'nav/bug.j2'); see jira_list_templates. Omit to apply the configured convention template, if any.
template_params Optional[Dict[str, Any]] None Extra variables available to the template; they override same-named call fields.

Class VerifyAuthInput

Input for verifying Jira authentication.

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally