Skip to content

Conversation

@michelle0927
Copy link
Collaborator

@michelle0927 michelle0927 commented Oct 9, 2025

Resolves #18698

Summary by CodeRabbit

  • New Features
    • Added an action to list all conversations for a ticket, with pagination and a configurable maximum results limit. Provides a summary of the number of conversations retrieved.
  • Enhancements
    • Get Ticket now supports an optional “include” setting (conversations, requester, company, stats) to enrich the returned data. Default behavior remains unchanged if not set.
  • Chores
    • Updated component versions (Freshdesk package to 0.6.0; Get Ticket action patch release).

@vercel
Copy link

vercel bot commented Oct 9, 2025

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

2 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
pipedream-docs Ignored Ignored Oct 9, 2025 8:17pm
pipedream-docs-redirect-do-not-edit Ignored Ignored Oct 9, 2025 8:17pm

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 9, 2025

Walkthrough

Adds an optional include parameter to the Freshdesk Get Ticket action and introduces a new action to list all conversations for a ticket. Also bumps the Freshdesk component package version.

Changes

Cohort / File(s) Summary
Freshdesk: Get Ticket enhancement
components/freshdesk/actions/get-ticket/get-ticket.mjs
Version 0.1.6 → 0.1.7. Adds optional string[] prop include with options [conversations, requester, company, stats]. Passes include as query param (comma-joined) to freshdesk.getTicket when provided.
Freshdesk: New List Ticket Conversations action
components/freshdesk/actions/list-ticket-conversations/list-ticket-conversations.mjs
New action to list all conversations for a ticket. Defines listTicketConversations helper hitting /tickets/{ticketId}/conversations via _makeRequest. Uses getPaginatedResources with maxResults. Returns results and sets summary with count.
Package version bump
components/freshdesk/package.json
Version 0.5.0 → 0.6.0.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User
  participant Action as Get Ticket Action
  participant Freshdesk as Freshdesk API

  User->>Action: Run (ticketId, include[])
  Action->>Freshdesk: GET /tickets/{ticketId}?include=conversations,requester,...
  Freshdesk-->>Action: 200 OK (ticket JSON)
  Action-->>User: Return ticket (with optional included fields)
  note over Action: include omitted → no query param sent
Loading
sequenceDiagram
  autonumber
  actor User
  participant Action as List Ticket Conversations Action
  participant Helper as getPaginatedResources
  participant Freshdesk as Freshdesk API

  User->>Action: Run (ticketId, maxResults)
  Action->>Helper: fn=listTicketConversations, args={ticketId,$}, max=maxResults
  loop pages until done / max
    Helper->>Freshdesk: GET /tickets/{ticketId}/conversations?page=N
    Freshdesk-->>Helper: 200 OK (conversations page)
  end
  Helper-->>Action: All conversations (<= max)
  Action-->>User: Return conversations + summary(count)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20–30 minutes

Poem

I hopped through threads of tickets bright,
Pulled chats and notes in moonlit byte,
Include a tale, or pull them all—
Conversations answer every call.
Version bumps, my whiskers twitch—
Freshdesk hums, click-click, no glitch. 🐇✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description Check ⚠️ Warning The pull request description only includes a reference to the issue number and does not follow the repository’s required template or provide the WHY section explaining the purpose of the changes. Please update the description to follow the repository’s template by adding a WHY section that explains the motivation and context for adding the list ticket conversations action and updating the get-ticket include behavior.
✅ Passed checks (4 passed)
Check name Status Explanation
Title Check ✅ Passed The pull request title accurately describes the primary change by indicating a Freshdesk action that lists all ticket conversations and is specific enough for scanning without being overly verbose.
Linked Issues Check ✅ Passed The changes implement the main request by adding a new “List Conversations of a Ticket” action (#18698) and extend the existing get-ticket action with an include parameter to optionally return conversations, satisfying the linked issue’s coding objectives.
Out of Scope Changes Check ✅ Passed All modifications are directly related to the objectives of adding the new list-ticket-conversations action and enhancing the get-ticket action, with only version bumps otherwise, so no out-of-scope changes are present.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch issue-18698

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c888bba and 7be6ae4.

📒 Files selected for processing (3)
  • components/freshdesk/actions/get-ticket/get-ticket.mjs (2 hunks)
  • components/freshdesk/actions/list-ticket-conversations/list-ticket-conversations.mjs (1 hunks)
  • components/freshdesk/package.json (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: Lint Code Base
  • GitHub Check: Publish TypeScript components
  • GitHub Check: Verify TypeScript components
  • GitHub Check: pnpm publish
🔇 Additional comments (7)
components/freshdesk/package.json (1)

3-3: LGTM! Appropriate version bump.

The minor version bump from 0.5.0 to 0.6.0 correctly reflects the addition of a new action and the enhancement of an existing action.

components/freshdesk/actions/get-ticket/get-ticket.mjs (3)

7-7: LGTM! Appropriate version bump.

The patch version increment correctly reflects the addition of an optional parameter without breaking changes.


22-33: LGTM! Well-defined optional parameter.

The include prop is correctly configured as an optional string array with appropriate options that align with the Freshdesk API documentation. This enables users to request additional data (conversations, requester, company, stats) to be included in the ticket response.


35-50: LGTM! Correct implementation of the include parameter.

The conditional logic correctly handles the include parameter:

  • Joins the array with commas to create a properly formatted query string
  • Passes undefined when not provided, avoiding unnecessary empty objects

This implementation aligns with the PR objective to support the ?include=conversations parameter from the Freshdesk API.

components/freshdesk/actions/list-ticket-conversations/list-ticket-conversations.mjs (3)

1-28: LGTM! Well-structured action metadata and props.

The action is correctly configured with:

  • Appropriate key, name, and description
  • Correct annotations (read-only, non-destructive)
  • Proper use of propDefinitions for ticketId and maxResults

This implementation fulfills the main PR objective to add a "List All Conversations of a Ticket" action.


29-38: LGTM! Correct API endpoint implementation.

The listTicketConversations method correctly calls the Freshdesk API endpoint /tickets/${ticketId}/conversations, which aligns with the API documentation for listing ticket conversations.


39-53: LGTM! Proper pagination and summary handling.

The run method correctly:

  • Uses getPaginatedResources to handle pagination automatically
  • Respects the maxResults limit
  • Exports a clear summary with proper singular/plural formatting

The implementation follows established patterns in the codebase for paginated API actions.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Collaborator

@luancazarine luancazarine left a comment

Choose a reason for hiding this comment

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

Hi @michelle0927, LGTM! Ready for QA!

@vunguyenhung vunguyenhung merged commit 13c7230 into master Oct 10, 2025
10 checks passed
@vunguyenhung vunguyenhung deleted the issue-18698 branch October 10, 2025 03:02
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.

[ACTION] Freshdesk List All Conversations of a Ticket

3 participants