Skip to content
Merged
Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
5227f82
added boiler plate code
HarshGautam7101 Aug 14, 2025
f847dd0
added price endpoint action
HarshGautam7101 Aug 14, 2025
5d78903
added hourly ohlcv action
HarshGautam7101 Aug 14, 2025
026e5c1
added daily ohlcv endpoint action
HarshGautam7101 Aug 14, 2025
256b743
added moonshot tokens endpoint action
HarshGautam7101 Aug 14, 2025
5a9ce83
added tm grades tokens endpoint action
HarshGautam7101 Aug 14, 2025
fe51956
added tm grades historical tokens endpoint action
HarshGautam7101 Aug 14, 2025
1254807
added fundamental grades tokens endpoint action
HarshGautam7101 Aug 14, 2025
43fa7ca
added fundamental grades historical tokens endpoint action
HarshGautam7101 Aug 14, 2025
7668376
added technology grades tokens endpoint action
HarshGautam7101 Aug 14, 2025
674f23f
added technology grades historical tokens endpoint action
HarshGautam7101 Aug 14, 2025
c032ddb
added market metrics tokens endpoint action
HarshGautam7101 Aug 14, 2025
40eb782
added ai reports tokens endpoint action
HarshGautam7101 Aug 14, 2025
d3ddaea
added crypto investors tokens endpoint action
HarshGautam7101 Aug 14, 2025
cd8b855
added top market cap tokens endpoint action
HarshGautam7101 Aug 14, 2025
068bf3b
added resistance and support tokens endpoint action
HarshGautam7101 Aug 14, 2025
34182b3
added hourly trading signals tokens endpoint action
HarshGautam7101 Aug 14, 2025
b79de6b
added quantmetrics tokens endpoint action
HarshGautam7101 Aug 14, 2025
0f5997a
added scenario analysis tokens endpoint action
HarshGautam7101 Aug 14, 2025
9868b59
added correlation tokens endpoint action
HarshGautam7101 Aug 14, 2025
8c25d8e
added indices tokens endpoint action
HarshGautam7101 Aug 14, 2025
e18265e
added indices holdings tokens endpoint action
HarshGautam7101 Aug 14, 2025
ce3e304
added indices performance tokens endpoint action
HarshGautam7101 Aug 14, 2025
005ef63
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 15, 2025
9d51809
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 19, 2025
b7b46b7
updated readme
HarshGautam7101 Aug 19, 2025
13a06c6
Merge branch 'ENG-8702,ENG-8703,ENG-8704' of https://github.com/Harsh…
HarshGautam7101 Aug 19, 2025
aa18f0e
Update README.md
HarshGautam7101 Aug 19, 2025
eb6853b
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 19, 2025
e81299e
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 21, 2025
7fdd3ab
feat: improve component documentation and validation
HarshGautam7101 Aug 22, 2025
5a2c7fe
feat: improve component documentation and validation
HarshGautam7101 Aug 22, 2025
333c3eb
chore: clean up token_metrics component and update dependencies
HarshGautam7101 Aug 25, 2025
56492ff
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 25, 2025
b34dd5c
Update components/token_metrics/actions/get-market-metrics/get-market…
GTFalcao Aug 26, 2025
330afc9
style: apply code formatting and linting fixes to token_metrics compo…
HarshGautam7101 Aug 27, 2025
7c8ef12
Merge branch 'master' into ENG-8702,ENG-8703,ENG-8704
HarshGautam7101 Aug 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 29 additions & 4 deletions components/token_metrics/README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,36 @@
# Overview

The Token Metrics API offers access to a trove of cryptocurrency data, including analytics, rankings, and predictions that leverage artificial intelligence and expert insights. With this API, you can automate investment strategies, integrate up-to-date crypto data into your applications, and stay informed with the latest market trends. When used on Pipedream, it allows you to build robust, serverless workflows that can react to various triggers and integrate with numerous services for a seamless data handling experience.
Token Metrics API on Pipedream allows you to access comprehensive cryptocurrency data and analytics. Integrate token metrics, market data, and analytics into your workflows to build powerful automation solutions for cryptocurrency trading, portfolio management, and market analysis.

# Example Use Cases

- **Crypto Alert System**: Build a workflow on Pipedream that monitors the Token Metrics API for significant changes in crypto ratings or predictions. When certain thresholds are met, use the integrated Twilio app to send SMS alerts, ensuring you or your audience stay up-to-date on important market movements.
- **Automated Portfolio Tracking**: Monitor your cryptocurrency portfolio by fetching token data and sending alerts when prices hit certain thresholds. Integrate with email services or Slack to receive real-time notifications.

- **Investment Tracker**: Create a Pipedream workflow that pulls daily investment insights and portfolio analytics from the Token Metrics API and logs them to a Google Sheets document. This allows for easy tracking and historical data analysis, helping to refine investment strategies over time.
- **Market Analysis Dashboard**: Collect token metrics data on a schedule and send it to Google Sheets or Airtable to create comprehensive market analysis dashboards with historical data tracking.

- **Market Dashboard Sync**: Use Pipedream to set up a workflow where market data and analytics from the Token Metrics API are fetched periodically and pushed to a real-time dashboard built with Geckoboard. This keeps your team or clients informed with the latest crypto market trends and forecasts.
- **Trading Signal Automation**: Use token analytics data to trigger automated trading signals, sending buy/sell recommendations via webhooks to trading platforms or notification services.

- **Research and Due Diligence**: Automatically fetch comprehensive token data for research purposes, combining it with other data sources to create detailed investment analysis reports.

# Authentication

To use the Token Metrics API, you'll need:

1. A Token Metrics account
2. An API key from your Token Metrics dashboard

The API uses Bearer token authentication. Your API key should be kept secure and not shared publicly.

# Available Actions

- **Get Tokens**: Retrieve a list of tokens with comprehensive metrics and analytics data
- **Get Token Details**: Fetch detailed information for a specific token
- **Search Tokens**: Search for tokens by name, symbol, or other criteria

# Rate Limits

Please refer to the Token Metrics API documentation for current rate limits and usage guidelines.

# Support

For issues related to the Token Metrics API itself, please contact Token Metrics support. For Pipedream-specific issues, please reach out via the Pipedream community.
75 changes: 75 additions & 0 deletions components/token_metrics/actions/get-ai-reports/get-ai-reports.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
import tokenMetrics from "../../token_metrics.app.mjs";
import { ENDPOINTS, FILTER_DEFINITIONS } from "../../common/constants.mjs";
import { buildParams, generateFilterSummary } from "../../common/utils.mjs";

const endpoint = ENDPOINTS.AI_REPORTS;

export default {
key: "token_metrics-get-ai-reports",
name: "Get AI Reports",
description: `${endpoint.description}. [See the documentation](https://developers.tokenmetrics.com/reference/ai-reports)`,
version: "0.0.1",
type: "action",
props: {
tokenMetrics,
// Filter props based on endpoint configuration and API documentation
tokenId: {
...FILTER_DEFINITIONS.token_id,
description: "Comma Separated Token IDs. Click here to access the list of token IDs. Example: 37493,3484",
},
symbol: {
...FILTER_DEFINITIONS.symbol,
description: "Comma Separated Token Symbols. Click here to access the list of token symbols. Example: APX,PAAL",
},
// Pagination props
limit: {
propDefinition: [
tokenMetrics,
"limit",
],
description: "Limit the number of items in response. Defaults to 50",
default: 50,
},
page: {
propDefinition: [
tokenMetrics,
"page",
],
description: "Enables pagination and data retrieval control by skipping a specified number of items before fetching data. Page should be a non-negative integer, with 1 indicating the beginning of the dataset. Defaults to 1",
default: 1,
},
},
async run({ $ }) {
// Build parameters using utility function
const params = buildParams(this, endpoint.filters);

try {
const response = await this.tokenMetrics.getAiReports({
$,
params,
});

// Generate summary using utility function
const filterSummary = generateFilterSummary(this, endpoint.filters);

// Use $ context for export
if ($ && $.export) {
const dataLength = response.data?.length || 0;
$.export("$summary", `Successfully retrieved AI reports for ${dataLength} tokens${filterSummary}`);
}

return response;
} catch (error) {
// Enhanced error handling
const errorMessage = error.response?.data?.message || error.message || "An error occurred";
const statusCode = error.response?.status;

if ($ && $.export) {
$.export("$summary", `Error: ${errorMessage}`);
}

// Throw a more descriptive error
throw new Error(`Token Metrics API Error (${statusCode || 'Unknown'}): ${errorMessage}`);
}
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
import tokenMetrics from "../../token_metrics.app.mjs";
import { ENDPOINTS, FILTER_DEFINITIONS } from "../../common/constants.mjs";
import { buildParams, generateFilterSummary } from "../../common/utils.mjs";

const endpoint = ENDPOINTS.CORRELATION;

export default {
key: "token_metrics-get-correlation",
name: "Get Correlation",
description: `${endpoint.description}. [See the documentation](https://developers.tokenmetrics.com/reference/correlation)`,
version: "0.0.1",
type: "action",
props: {
tokenMetrics,
// Filter props based on endpoint configuration and API documentation
tokenId: {
...FILTER_DEFINITIONS.token_id,
description: "Comma Separated Token IDs. Click here to access the list of token IDs. Example: 3375,3306",
},
symbol: {
...FILTER_DEFINITIONS.symbol,
description: "Comma Separated Token Symbols. Click here to access the list of token symbols. Example: BTC,ETH",
},
category: {
...FILTER_DEFINITIONS.category,
description: "Comma separated category name. Click here to access the list of categories. Example: layer-1,nft",
},
exchange: {
...FILTER_DEFINITIONS.exchange,
description: "Comma separated exchange name. Click here to access the list of exchanges. Example: gate,binance",
},
// Pagination props
limit: {
propDefinition: [
tokenMetrics,
"limit",
],
description: "Limit the number of items in response. Defaults to 50",
default: 50,
},
page: {
propDefinition: [
tokenMetrics,
"page",
],
description: "Enables pagination and data retrieval control by skipping a specified number of items before fetching data. Page should be a non-negative integer, with 1 indicating the beginning of the dataset. Defaults to 1",
default: 1,
},
},
async run({ $ }) {
// Build parameters using utility function
const params = buildParams(this, endpoint.filters);

try {
const response = await this.tokenMetrics.getCorrelation({
$,
params,
});

// Generate summary using utility function
const filterSummary = generateFilterSummary(this, endpoint.filters);

// Use $ context for export
if ($ && $.export) {
const dataLength = response.data?.length || 0;
$.export("$summary", `Successfully retrieved correlation data for ${dataLength} tokens${filterSummary}`);
}

return response;
} catch (error) {
// Enhanced error handling
const errorMessage = error.response?.data?.message || error.message || "An error occurred";
const statusCode = error.response?.status;

if ($ && $.export) {
$.export("$summary", `Error: ${errorMessage}`);
}

// Throw a more descriptive error
throw new Error(`Token Metrics API Error (${statusCode || 'Unknown'}): ${errorMessage}`);
}
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
import tokenMetrics from "../../token_metrics.app.mjs";
import { ENDPOINTS, FILTER_DEFINITIONS } from "../../common/constants.mjs";
import { buildParams, generateFilterSummary } from "../../common/utils.mjs";

const endpoint = ENDPOINTS.CRYPTO_INVESTORS;

export default {
key: "token_metrics-get-crypto-investors",
name: "Get Crypto Investors",
description: `${endpoint.description}. [See the documentation](https://developers.tokenmetrics.com/reference/crypto-investors)`,
version: "0.0.1",
type: "action",
props: {
tokenMetrics,
// Pagination props
limit: {
propDefinition: [
tokenMetrics,
"limit",
],
description: "Limit the number of items in response. Defaults to 50",
default: 50,
},
page: {
propDefinition: [
tokenMetrics,
"page",
],
description: "Enables pagination and data retrieval control by skipping a specified number of items before fetching data. Page should be a non-negative integer, with 1 indicating the beginning of the dataset. Defaults to 1",
default: 1,
},
},
async run({ $ }) {
// Build parameters using utility function
const params = buildParams(this, endpoint.filters);

try {
const response = await this.tokenMetrics.getCryptoInvestors({
$,
params,
});

// Generate summary using utility function
const filterSummary = generateFilterSummary(this, endpoint.filters);

// Use $ context for export
if ($ && $.export) {
const dataLength = response.data?.length || 0;
$.export("$summary", `Successfully retrieved ${dataLength} crypto investors${filterSummary}`);
}

return response;
} catch (error) {
// Enhanced error handling
const errorMessage = error.response?.data?.message || error.message || "An error occurred";
const statusCode = error.response?.status;

if ($ && $.export) {
$.export("$summary", `Error: ${errorMessage}`);
}

// Throw a more descriptive error
throw new Error(`Token Metrics API Error (${statusCode || 'Unknown'}): ${errorMessage}`);
}
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
import tokenMetrics from "../../token_metrics.app.mjs";
import { ENDPOINTS, FILTER_DEFINITIONS } from "../../common/constants.mjs";
import { buildParams, generateFilterSummary } from "../../common/utils.mjs";

const endpoint = ENDPOINTS.DAILY_OHLCV;

export default {
key: "token_metrics-get-daily-ohlcv",
name: "Get Daily OHLCV",
description: `${endpoint.description}. [See the documentation](https://developers.tokenmetrics.com/reference/daily-ohlcv)`,
version: "0.0.1",
type: "action",
props: {
tokenMetrics,
// Filter props based on endpoint configuration and screenshot
tokenId: {
...FILTER_DEFINITIONS.token_id,
description: "Comma Separated Token IDs. Click here to access the list of token IDs. Example: 3375",
},
symbol: {
...FILTER_DEFINITIONS.symbol,
description: "Comma Separated Token Symbols. Click here to access the list of token symbols. Example: BTC",
},
tokenName: {
...FILTER_DEFINITIONS.token_name,
description: "Comma Separated Crypto Asset Names (e.g., Bitcoin, Ethereum). Click here to access the list of token names. Example: Bitcoin",
},
startDate: {
...FILTER_DEFINITIONS.start_date,
description: "Start Date accepts date as a string - YYYY-MM-DD format. Note: The Start Date cannot be earlier than the past 30 days from the current date. Example: 2025-01-01",
},
endDate: {
...FILTER_DEFINITIONS.end_date,
description: "End Date accepts date as a string - YYYY-MM-DD format. Example: 2025-01-23",
},
// Pagination props
limit: {
propDefinition: [
tokenMetrics,
"limit",
],
description: "Limit the number of items in response. Defaults to 50",
default: 50,
},
page: {
propDefinition: [
tokenMetrics,
"page",
],
description: "Enables pagination and data retrieval control by skipping a specified number of items before fetching data. Page should be a non-negative integer, with 1 indicating the beginning of the dataset. Defaults to 1",
default: 1,
},
},
async run({ $ }) {
// Build parameters using utility function
const params = buildParams(this, endpoint.filters);

try {
const response = await this.tokenMetrics.getDailyOhlcv({
$,
params,
});

// Generate summary using utility function
const filterSummary = generateFilterSummary(this, endpoint.filters);

// Use $ context for export
if ($ && $.export) {
const dataLength = response.data?.length || 0;
$.export("$summary", `Successfully retrieved ${dataLength} daily OHLCV records${filterSummary}`);
}

return response;
} catch (error) {
// Enhanced error handling
const errorMessage = error.response?.data?.message || error.message || "An error occurred";
const statusCode = error.response?.status;

if ($ && $.export) {
$.export("$summary", `Error: ${errorMessage}`);
}

// Throw a more descriptive error
throw new Error(`Token Metrics API Error (${statusCode || 'Unknown'}): ${errorMessage}`);
}
},
};
Loading