Skip to content

Conversation

@aadamgough
Copy link
Collaborator

Summary

Improved both slack output and jira params for tools. Added one more jira operation

Type of Change

  • Bug fix
  • New feature

Testing

Manually

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel
Copy link

vercel bot commented Dec 19, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Review Updated (UTC)
docs Skipped Skipped Dec 19, 2025 1:49am

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Dec 19, 2025

Greptile Summary

This PR enhances Jira and Slack tool functionality with improved UX and expanded capabilities.

Slack Improvements:

  • Added ids and names arrays to list_channels and list_users outputs for easier downstream access to identifiers without array mapping

Jira Enhancements:

  • New jira_get_users operation supports fetching all users or a specific user by account ID with pagination
  • Expanded jira_write operation with 8 new optional parameters: labels, duedate, reporter, environment, customFieldId, customFieldValue, plus improved priority (ID/name support) and assignee visibility
  • Assignee assignment moved to separate PUT request after issue creation (more reliable approach)
  • Priority now accepts both numeric IDs and string names with automatic detection
  • Custom fields support with flexible ID format handling

UI/UX:

  • Refactored tag-dropdown array indexing to handle any array type (not just files), enabling better support for new Slack output arrays
  • Added comprehensive UI blocks for all new Jira parameters

Documentation:

  • Updated Jira docs with new parameters and operations

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • All changes are additive enhancements that maintain backward compatibility. The refactoring in tag-dropdown improves generality without breaking existing functionality. New Jira parameters are optional and well-validated. Only minor style issue with hardcoded "Team UUID" title.
  • apps/sim/blocks/blocks/jira.ts - Update generic custom field title from "Team UUID" to "Custom Field Value"

Important Files Changed

Filename Overview
apps/sim/tools/jira/get_users.ts New Jira operation to fetch users with pagination support and single user lookup
apps/sim/tools/jira/write.ts Enhanced write operation with additional fields (labels, duedate, reporter, environment, custom fields) and improved visibility for priority and assignee
apps/sim/app/api/tools/jira/write/route.ts Implemented handling for new Jira fields (priority with ID/name support, labels, duedate, reporter, environment, custom fields), and moved assignee to separate PUT request
apps/sim/blocks/blocks/jira.ts Added UI blocks for new Jira fields and get_users operation; found misleading title "Team UUID" for customFieldValue
apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tag-dropdown/tag-dropdown.tsx Refactored array field indexing logic to be more generic, handling any array type instead of just files

Sequence Diagram

sequenceDiagram
    participant User
    participant UI as Workflow Editor
    participant JiraWrite as Jira Write API
    participant JiraAPI as Jira API
    participant SlackTool as Slack Tools

    Note over User,SlackTool: Slack UX Improvements
    User->>SlackTool: Call list_channels/list_users
    SlackTool->>SlackTool: Map channels/users to extract ids and names
    SlackTool-->>User: Return {channels, ids, names, count}
    User->>UI: Select from dropdown using ids/names arrays
    
    Note over User,JiraAPI: Jira Write Enhancements
    User->>UI: Create Jira issue with new fields
    UI->>JiraWrite: POST with labels, duedate, reporter, etc.
    JiraWrite->>JiraWrite: Validate and transform fields
    JiraWrite->>JiraWrite: Handle priority (detect ID vs name)
    JiraWrite->>JiraWrite: Format environment as ADF document
    JiraWrite->>JiraWrite: Process custom field ID format
    JiraWrite->>JiraAPI: POST /issue (create without assignee)
    JiraAPI-->>JiraWrite: Return {key, fields}
    alt Assignee provided
        JiraWrite->>JiraAPI: PUT /issue/{key}/assignee
        JiraAPI-->>JiraWrite: 204 No Content
    end
    JiraWrite-->>User: Return {issueKey, url, assigneeId}
    
    Note over User,JiraAPI: New Get Users Operation
    User->>JiraWrite: Request jira_get_users
    JiraWrite->>JiraAPI: GET /users/search?startAt&maxResults
    JiraAPI-->>JiraWrite: Return user array
    JiraWrite-->>User: Return {users, total, startAt, maxResults}
Loading

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

12 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

Comment on lines 256 to 257
id: 'customFieldValue',
title: 'Team UUID',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style: Misleading title for generic custom field parameter

Suggested change
id: 'customFieldValue',
title: 'Team UUID',
title: 'Custom Field Value',

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/sim/blocks/blocks/jira.ts
Line: 256:257

Comment:
**style:** Misleading title for generic custom field parameter

```suggestion
      title: 'Custom Field Value',
```

<sub>Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!</sub>

How can I resolve this? If you propose a fix, please make it concise.

@aadamgough aadamgough merged commit fc40b4f into staging Dec 19, 2025
10 checks passed
@aadamgough aadamgough deleted the fix/tool-out branch December 19, 2025 01:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants