Skip to main content

Module jira_import

Module jira_import 

Source
Expand description

Free-tier Jira platform REST only (no Marketplace apps).

Endpoint map (official Cloud + Server/DC docs):

OpEndpointNotes
ProbeGET /rest/api/2/myself (+ serverInfo)Cloud Free email+API token or Server PAT
SearchGET /rest/api/2/search?jql=&fields=summaryFree JQL; Server also allows POST search
Comments GETGET /rest/api/2/issue/{key}/commentWiki string or Cloud ADF body
Comment POSTServer: POST /rest/api/2/.../comment wiki Β· Cloud: POST /rest/api/3/.../comment ADFNo paid formatters

Import writes drafts under corpus/imports/ only. Write is explicit one-shot comment post (review-before-migrate), not bulk library sync.

StructsΒ§

CommentCreateResponse πŸ”’
CommentsResponse πŸ”’
IssueComment
One comment on a Jira issue, with its body still in Jira wiki markup.
IssueSummary
One issue found by a JQL search: key plus its summary.
JiraConfig
Jira instance connection details.
JiraProbe
Result of a free-tier connectivity probe (/myself + optional serverInfo).
MyselfResponse πŸ”’
PostedComment
One comment created via free REST POST.
RawComment πŸ”’
RawUser πŸ”’
SearchFields πŸ”’
SearchIssue πŸ”’
SearchResponse πŸ”’
ServerInfoResponse πŸ”’

EnumsΒ§

CommentBodyFormat
How to encode free write comment bodies for platform REST.
JiraAuth
How to authenticate against the Jira REST API.

FunctionsΒ§

adf_to_plain_text πŸ”’
adf_walk πŸ”’
apply_auth πŸ”’
build_comment_post_request πŸ”’
build_comments_request_at πŸ”’
build_myself_request πŸ”’
build_search_request_at πŸ”’
build_server_info_request πŸ”’
comment_body_to_text
Flatten free-platform comment bodies: wiki strings stay as-is; Cloud ADF (Atlassian Document Format) is reduced to plain text without Marketplace apps.
comment_post_payload πŸ”’
comment_post_url πŸ”’
Free platform comment endpoints (official Cloud/Server REST β€” no Marketplace).
default_import_dir
Where imported drafts land by default (never auto-indexed or quality-checked).
draft_markdown
Render one issue’s comments as a review draft: front matter plus one section per comment. id must already carry the snell- prefix.
fetch_comments
Fetch all comments for one issue (api/2, then api/3 on Cloud-style hosts).
format_probe
Format a probe result for CLI stdout.
http_client πŸ”’
import_jira
Import issues matching jql into out_dir as review drafts (never corpus/responses/). Returns the paths written, or, when dry_run is set, the paths that would be written without touching the filesystem or fetching comments.
is_cloud_host
True when the base URL looks like Jira Cloud Free/Standard host.
parse_comment_create_response πŸ”’
parse_comments_response πŸ”’
parse_myself_response πŸ”’
parse_search_response πŸ”’
parse_server_info_response πŸ”’
plain_text_to_adf
Build minimal free ADF document from plain/wiki text (Cloud comment write path).
post_comment_from_markdown
Convert a markdown corpus file with pandoc jira writer, then POST as a comment.
post_comment_from_markdown_with_format
Like post_comment_from_markdown with an explicit free-tier body format.
post_issue_comment
POST a comment via free platform REST (wiki on Server/DC, ADF on Cloud Free).
post_issue_comment_with_format
Like post_issue_comment with an explicit body format.
probe_jira
Probe free Jira REST: authenticated identity + optional server banner.
search_all_issues
Search for issues matching jql, paginating until Jira reports no more.
search_page πŸ”’
Execute one free-tier search page, trying platform URL candidates on failure.
search_url_candidates πŸ”’
Free search URL candidates (Server v2 first; Cloud Free may prefer v3).
slugify
Turn a title into a slug: lowercase ASCII alphanumerics, everything else collapsed to a single -, with no leading, trailing, or repeated dash.