jira-ticket-creator
v1.0.5
Published
CLI tool to create Jira tickets with markdown support
Readme
Jira Ticket Creator
A powerful CLI tool to create Jira tickets with Markdown support.
Features
- Create Jira tickets directly from the command line
- Convert Markdown to Jira markup
- Support for custom fields, components, and labels
- Automatic user assignment
- Flexible input options (file or inline text)
Installation
npm install -g jira-ticket-creatorUsage
create-jira-ticket [options]
# or
npx jira-ticket-creator [options]Options
| Option | Alias | Description | Required |
|--------|-------|-------------|----------|
| --host | -h | Jira host URL | Yes |
| --email | -e | Your Jira email | Yes |
| --api-token | -t | Your Jira API token | Yes |
| --project-key | -p | Jira project key | Yes |
| --summary | -s | Ticket summary | Yes |
| --markdown | -m | Markdown content (file path or inline text) | Yes |
| --issue-type | -i | Issue type (default: "Task") | No |
| --parent-key | | Parent issue key for sub-tasks | No |
| --labels | -l | Comma-separated list of labels | No |
| --priority | | Priority of the issue | No |
| --assignee | -a | Assignee (username or email) | No |
| --components | -c | Comma-separated list of components | No |
| --custom-fields | | JSON string of custom fields | No |
Example
create-jira-ticket \
--host "https://your-domain.atlassian.net" \
--email "[email protected]" \
--api-token "your-api-token" \
--project-key "PROJ" \
--summary "Implement new feature" \
--markdown "feature-description.md" \
--issue-type "Story" \
--labels "frontend,urgent" \
--priority "High" \
--assignee "[email protected]" \
--components "UI,API" \
--custom-fields '{"customfield_10001": "Custom Value"}'Markdown Support
This tool converts Markdown to Jira markup. Supported Markdown features include:
- Headers (H1-H6)
- Bold and italic text
- Ordered and unordered lists
- Code blocks and inline code
- Links and images
- Blockquotes
- Horizontal rules
- Tables
API Token
To use this tool, you need to generate an API token for your Jira account:
- Log in to https://id.atlassian.com/manage/api-tokens
- Click "Create API token"
- Copy the generated token
Never share your API token or commit it to version control.
Error Handling
The tool provides detailed error messages for various scenarios, including:
- Invalid input formats
- Network errors
- Jira API errors
- Exceeded Jira limits (e.g., description length)
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
If you encounter any problems or have any questions, please open an issue on the GitHub repository.
