Skip to content

Conversation

HarshGautam7101
Copy link
Contributor

@HarshGautam7101 HarshGautam7101 commented Aug 15, 2025

WHY

Summary by CodeRabbit

  • New Features
    • Added multiple Token Metrics actions: prices, hourly/daily OHLCV, trading signals (hourly and daily), TM/Fundamental/Technology grades (current and historical), market metrics, moonshot tokens, AI reports, crypto investors, resistance/support, quantmetrics, scenario analysis, correlation, and indices (list, holdings, performance).
    • Introduced pagination with page support and sensible defaults.
  • Documentation
    • Rewrote README to API-first format with authentication, available actions, rate limits, and support details.
  • Refactor
    • Standardized API client, centralized filter definitions, and consistent success/error summaries.
  • Chores
    • Updated dependency versions and package metadata.

Copy link

vercel bot commented Aug 15, 2025

@HarshGautam7101 is attempting to deploy a commit to the Pipedreamers Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Aug 15, 2025

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

1 Skipped Deployment
Project Deployment Preview Comments Updated (UTC)
pipedream-docs-redirect-do-not-edit Ignored Ignored Aug 27, 2025 1:28pm

Copy link
Contributor

coderabbitai bot commented Aug 15, 2025

Walkthrough

Adds centralized endpoint/constants and utilities, refactors the Token Metrics app to a generic API client with standardized error handling, and rewrites README. Introduces numerous new action modules and updates existing ones to use shared utilities (buildParams, generateFilterSummary) and new endpoint wrappers with consistent pagination and summaries.

Changes

Cohort / File(s) Summary
Documentation
components/token_metrics/README.md
Rewrote README to API-first doc style; added auth, actions, rate limits, and support sections; removed platform-specific examples.
Core client and shared utilities
components/token_metrics/token_metrics.app.mjs, components/token_metrics/common/constants.mjs, components/token_metrics/common/utils.mjs, components/token_metrics/package.json
Refactored app to generic API client with standardized headers, error handling, and endpoint wrappers; added centralized ENDPOINTS, FILTER_DEFINITIONS, ERROR_MESSAGES; introduced param and error utilities; updated package metadata and dependency.
Refactored existing actions
components/token_metrics/actions/get-market-metrics/get-market-metrics.mjs, components/token_metrics/actions/get-tokens/get-tokens.mjs
Migrated to shared ENDPOINTS/filters, buildParams, generateFilterSummary; switched to tokenMetrics client; added pagination and enhanced error/success summaries.
Grades actions (new)
.../actions/get-fundamental-grades/*, .../actions/get-technology-grades/*, .../actions/get-tm-grades/*
Added actions for current and historical Fundamental, Technology, and TM grades with filter props, pagination, standardized run flow, and error handling.
OHLCV actions (new)
.../actions/get-hourly-ohlcv/get-hourly-ohlcv.mjs, .../actions/get-daily-ohlcv/get-daily-ohlcv.mjs
Added hourly and daily OHLCV actions using shared utilities and endpoint wrappers with date filters and pagination.
Signals actions (new)
.../actions/get-trading-signals/get-trading-signals.mjs, .../actions/get-hourly-trading-signals/get-hourly-trading-signals.mjs
Added trading signals (daily/hourly) actions with extensive filters, pagination, summaries, and standardized error handling.
Indices actions (new)
.../actions/get-indices/get-indices.mjs, .../actions/get-indices-holdings/get-indices-holdings.mjs, .../actions/get-indices-performance/get-indices-performance.mjs
Added indices listing, holdings, and performance actions with relevant filters, pagination, and shared flow.
Market/data actions (new)
.../actions/get-price/get-price.mjs, .../actions/get-quantmetrics/get-quantmetrics.mjs, .../actions/get-top-market-cap-tokens/get-top-market-cap-tokens.mjs, .../actions/get-moonshot-tokens/get-moonshot-tokens.mjs, .../actions/get-ai-reports/get-ai-reports.mjs, .../actions/get-crypto-investors/get-crypto-investors.mjs, .../actions/get-resistance-support/get-resistance-support.mjs, .../actions/get-scenario-analysis/get-scenario-analysis.mjs, .../actions/get-correlation/get-correlation.mjs
Added multiple data retrieval actions (price, quantmetrics, top market cap, moonshot, AI reports, crypto investors, resistance/support, scenario analysis, correlation) with filter props, pagination, standardized summaries, and error handling.

Sequence Diagram(s)

sequenceDiagram
  participant User
  participant Action
  participant Utils as Utils (buildParams / generateFilterSummary)
  participant App as TokenMetrics App
  participant API as Token Metrics API

  User->>Action: Invoke action with props
  Action->>Utils: buildParams(props, endpoint.filters)
  Action->>App: makeApiCall(endpoint, params)
  App->>API: GET /v2/<endpoint>?params
  API-->>App: Response / Error
  alt Success
    App-->>Action: Data
    Action->>Utils: generateFilterSummary(props, filters)
    Action-->>User: Return data (+ $summary)
  else Error
    App-->>Action: Error
    Action-->>User: Throw "Token Metrics API Error (status): message"
  end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45–60 minutes

Poem

Hop-hop! I wired new routes to the moon,
With filters that sing a tidy tune.
Params in a row, errors kept tight,
Summaries sparkle, pagination’s light.
From grades to signals, the data streams bloom—
A rabbit’s refactor, swift as a zoom! 🐇✨

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@adolfo-pd adolfo-pd added the User submitted Submitted by a user label Aug 15, 2025
@pipedream-component-development
Copy link
Collaborator

Thank you so much for submitting this! We've added it to our backlog to review, and our team has been notified.

@pipedream-component-development
Copy link
Collaborator

Thanks for submitting this PR! When we review PRs, we follow the Pipedream component guidelines. If you're not familiar, here's a quick checklist:

Copy link
Collaborator

@GTFalcao GTFalcao left a comment

Choose a reason for hiding this comment

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

Hi there, thanks for your contribution! I see you've added a lot of components, that is greatly appreciated.

I've commented on a few general changes that need to be made across most or all of the components, before this is ready to be merged. Let me know if you need any assistance

@GTFalcao GTFalcao moved this from Ready for PR Review to Changes Required in Component (Source and Action) Backlog Aug 21, 2025
- Add markdown formatting to all example values with backticks
- Highlight date formats (`YYYY-MM-DD`) in prop descriptions
- Add `min: 1` validation to all page props across 19 action files
- Remove verbose pagination descriptions in favor of built-in validation
- Standardize prop definitions using `propDefinitions` from app file
- Convert comma-separated string props to `string[]` type for better UX
- Remove redundant `if ($ && $.export)` checks from all actions
- Remove custom `try/catch` blocks to leverage Pipedream's native error handling
- Clean up `handleApiError` utility function and related imports
- Fix prop descriptions to use proper options instead of text descriptions
- Update README.md to be more concise and professional per feedback

This refactor improves code maintainability, user experience, and follows
Pipedream component best practices for validation, error handling, and
documentation formatting.
- Add markdown formatting to all example values with backticks
- Highlight date formats (`YYYY-MM-DD`) in prop descriptions
- Add `min: 1` validation to all page props across 19 action files
- Remove verbose pagination descriptions in favor of built-in validation
- Standardize prop definitions using `propDefinitions` from app file
- Convert comma-separated string props to `string[]` type for better UX
- Remove redundant `if ($ && $.export)` checks from all actions
- Remove custom `try/catch` blocks to leverage Pipedream's native error handling
- Clean up `handleApiError` utility function and related imports
- Fix prop descriptions to use proper options instead of text descriptions
- Update README.md to be more concise and professional per feedback

This refactor improves code maintainability, user experience, and follows
Pipedream component best practices for validation, error handling, and
documentation formatting.
@HarshGautam7101
Copy link
Contributor Author

HarshGautam7101 commented Aug 22, 2025

@GTFalcao I’ve implemented all the required changes, it should be good now. Can you please recheck?

Copy link
Collaborator

@GTFalcao GTFalcao left a comment

Choose a reason for hiding this comment

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

If you're able, running pnpm install -r and committing the pnpm-lock.yaml file will ensure the PR checks run properly.

I left a few comments, but I'm moving the PR forward to be QA'd, as these comments do not impact functionality.

@GTFalcao GTFalcao moved this from Changes Required to Ready for QA in Component (Source and Action) Backlog Aug 24, 2025
@vunguyenhung vunguyenhung moved this from Ready for QA to Ready for Release in Component (Source and Action) Backlog Aug 25, 2025
@vunguyenhung
Copy link
Collaborator

Hi everyone, all test cases are passed! Ready for release!

Test report
https://vunguyenhung.notion.site/Eng-8702-eng-8703-eng-8704-259bf548bb5e817bae58ea56e2b5d15d

- Remove unused generateEndpointProps function from utils.mjs
- Update pnpm-lock.yaml to ensure PR checks run properly
- Clean up code by removing dead code that was never imported or used
@HarshGautam7101 HarshGautam7101 force-pushed the ENG-8702,ENG-8703,ENG-8704 branch from f0dd550 to 333c3eb Compare August 25, 2025 20:49
@HarshGautam7101
Copy link
Contributor Author

If you're able, running pnpm install -r and committing the pnpm-lock.yaml file will ensure the PR checks run properly.

I left a few comments, but I'm moving the PR forward to be QA'd, as these comments do not impact functionality.

Commited pnpm-lock.yaml file

@GTFalcao
Copy link
Collaborator

ESLint issues need to be adjusted before the PR can be merged:

npx eslint --fix components/token_metrics

…nent

- Fix import formatting across all action files
- Remove trailing whitespace from constants and other files
- Add proper newline endings to package.json
- Apply consistent spacing and formatting throughout
- Improve code readability and maintain style consistency
@HarshGautam7101
Copy link
Contributor Author

ESLint issues need to be adjusted before the PR can be merged:

npx eslint --fix components/token_metrics

@GTFalcao It's done !

@GTFalcao GTFalcao merged commit 1b4d96e into PipedreamHQ:master Aug 27, 2025
10 checks passed
@github-project-automation github-project-automation bot moved this from Ready for Release to Done in Component (Source and Action) Backlog Aug 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
User submitted Submitted by a user
Development

Successfully merging this pull request may close these issues.

5 participants