### Install Messari SDK (Bash) Source: https://docs.messari.io/examples/overview Provides the command to install the Messari SDK package. This is a prerequisite for using the SDK in a Node.js project. ```bash npm install @messari/client ``` -------------------------------- ### Install Messari Typescript SDK Source: https://docs.messari.io/quickstart Instructions for installing the Messari Typescript SDK using popular package managers like npm, pnpm, and yarn. This is the first step to integrating Messari's data and AI services into your project. ```bash # Using npm npm install @messari/sdk-ts # Using pnpm pnpm add @messari/sdk-ts # Using yarn yarn add @messari/sdk-ts ``` -------------------------------- ### Get Specific Asset Details Source: https://docs.messari.io/quickstart Retrieves detailed information for a specific asset. ```APIDOC ## GET /api/v1/assets/{assetId} ### Description Gets detailed information for a specific asset. ### Method GET ### Endpoint /api/v1/assets/{assetId} ### Parameters #### Path Parameters - **assetId** (string) - Required - The unique identifier of the asset. ### Request Example ```json {} ``` ### Response #### Success Response (200) - **(Response structure not detailed in the provided text)** #### Response Example ```json { "example": "(Response structure not detailed in the provided text)" } ``` ``` -------------------------------- ### AI Chat Completion with Messari SDK Source: https://docs.messari.io/quickstart Example of how to perform an AI chat completion using the Messari Typescript SDK. It demonstrates initializing the client with an API key and making a request to the OpenAI-compatible chat completions endpoint. The response content is then logged to the console. ```typescript import MessariSDK from "@messari/sdk-ts"; // Initialize the client const client = new MessariSDK({ apiKey: process.env["MESSARI_SDK_API_KEY"], }); // Use the AI service const response = await client.ai.openai.chat.generateCompletion({ messages: [ { role: "user", content: "What companies have both paradigm and a16z on their cap table?", MultiContent: [{}], }, ], inlineCitations: true, }); console.log(response.choices[0].message.content); ``` -------------------------------- ### Example Request (cURL) Source: https://docs.messari.io/api-reference/authentication An example of how to make a request to the Messari API using cURL, including the API key in the headers. ```APIDOC ## Example Request (cURL) ### Description This example demonstrates how to send a request to the Messari API using cURL, including the `x-messari-api-key` header. ### Method POST ### Endpoint `https://api.messari.io/ai/v1/chat/completions` ### Parameters #### Request Headers - **x-messari-api-key** (string) - Required - Your unique Messari API key. - **Content-Type** (string) - Required - `application/json` #### Request Body - **messages** (array) - Required - An array of message objects, where each object has a `role` and `content`. - **verbosity** (string) - Optional - Controls the verbosity of the response (e.g., `succinct`). - **response_format** (string) - Optional - Specifies the desired format of the response (e.g., `markdown`). ### Request Example ```bash curl --location 'https://api.messari.io/ai/v1/chat/completions' \ --header 'x-messari-api-key: YOUR_API_KEY_HERE' \ --header 'Content-Type: application/json' \ --data '{ "messages": [ { "role": "user", "content": "Briefly explain what the Hyperliquid HyperEVM is" } ], "verbosity": "succinct", "response_format": "markdown" }' ``` ``` -------------------------------- ### GET /user-management/v1/api/credits/allowance Source: https://docs.messari.io/api-reference/endpoints/user-management/get-v1-api-credits-allowance Retrieves the current credit allowance details for a team. This includes allocated credits, start and end dates, and team ID. ```APIDOC ## GET /user-management/v1/api/credits/allowance ### Description Returns the current credit allowance for the team. ### Method GET ### Endpoint https://api.messari.io/user-management/v1/api/credits/allowance ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example ```json { "message": "Request not applicable for GET" } ``` ### Response #### Success Response (200) - **data** (object) - Contains the allowance information. - **creditsAllocated** (integer) - The total number of credits allocated. - **endDate** (string) - The date and time when the credit allowance ends (ISO 8601 format). - **id** (string) - The unique identifier for the credit allowance. - **isActive** (boolean) - Indicates if the credit allowance is currently active. - **remainingCredits** (integer) - The number of credits remaining. - **startDate** (string) - The date and time when the credit allowance started (ISO 8601 format). - **teamId** (integer) - The identifier of the team the allowance belongs to. - **error** (string) - An error message if an error occurred (should be null on success). #### Response Example ```json { "data": { "creditsAllocated": 123, "endDate": "2023-11-07T05:31:56Z", "id": "", "isActive": true, "remainingCredits": 123, "startDate": "2023-11-07T05:31:56Z", "teamId": 123 }, "error": null } ``` #### Error Responses - **400 Bad Request**: Returned if the request is malformed. - **401 Unauthorized**: Returned if the API key is invalid or missing. - **404 Not Found**: Returned if the requested resource does not exist. - **500 Internal Server Error**: Returned if there is a server-side issue. ``` -------------------------------- ### Messari SDK AI Chat Completion Example (TypeScript) Source: https://docs.messari.io/examples/overview Demonstrates how to perform a basic AI chat completion using the Messari SDK. This requires an API key and the '@messari/client' package. It shows how to initialize the client, set up messages (including system and user roles), and call the chat completion endpoint. ```typescript import { MessariClient } from "@messari/client"; const client = new MessariClient({ apiKey: "YOUR_API_KEY" }); async function getChatResponse() { const response = await client.ai.chat.create({ messages: [ { role: "system", content: "You are a helpful assistant." }, { role: "user", content: "What is the current state of DeFi?" }, ], model: "messari-1", }); console.log(response.choices[0].message.content); } ``` -------------------------------- ### Install and Run Messari MCP Server (Bash) Source: https://docs.messari.io/mcp-server/overview Installs and runs the Messari MCP server using npx. Requires setting the MESSARI_SDK_API_KEY environment variable. ```bash export MESSARI_SDK_API_KEY="My API Key" npx -y @messari/sdk-ts-mcp@latest ``` -------------------------------- ### GET /signal/v0/assets Endpoint (OpenAPI YAML) Source: https://docs.messari.io/api-reference/endpoints/signal/asset-mindshare/get-v0-assets Defines the GET /signal/v0/assets endpoint using OpenAPI specification. It includes details on the server URL, request parameters (query, header), security requirements (API key), and possible responses (200, 400, 403, 500) with their respective schemas and examples. ```yaml paths: path: /signal/v0/assets method: get servers: - url: https://api.messari.io description: Messari API request: security: - title: apiKey parameters: query: {} header: X-Messari-API-Key: type: apiKey cookie: {} parameters: path: {} query: limit: schema: - type: integer description: Number of items per page pageSize: schema: - type: integer description: Number of items per page. Kept for backward compatibility page: schema: - type: integer description: Page number header: {} cookie: {} body: {} response: '200': application/json: schemaArray: - type: object properties: data: allOf: - items: $ref: '#/components/schemas/signalAsset' type: array error: allOf: - type: string metadata: allOf: - $ref: '#/components/schemas/SnapshotListingMetadata' requiredProperties: - data examples: example: value: data: - id: mindshare: latestPercentage: IsNull: true Value: 123 latestScore: IsNull: true Value: 123 percentageChange1d: IsNull: true Value: 123 percentageChange30d: IsNull: true Value: 123 percentageChange7d: IsNull: true Value: 123 rank: IsNull: true Value: 123 scoreChange1d: IsNull: true Value: 123 scoreChange30d: IsNull: true Value: 123 scoreChange7d: IsNull: true Value: 123 name: sentiment: latestScore: IsNull: true Value: 123 scoreChange180d: IsNull: true Value: 123 scoreChange1d: IsNull: true Value: 123 scoreChange1y: IsNull: true Value: 123 scoreChange30d: IsNull: true Value: 123 scoreChange7d: IsNull: true Value: 123 scoreChange90d: IsNull: true Value: 123 scoreChangeYTD: IsNull: true Value: 123 slug: symbol: error: metadata: page: 123 pageSize: 123 totalPages: 123 totalRows: 123 description: Default response '400': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Bad Request '403': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Forbidden '500': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Internal Server Error deprecated: false type: path components: schemas: AssetMindshare: {} ``` -------------------------------- ### OpenAPI Specification for Market Timeseries Data Source: https://docs.messari.io/api-reference/endpoints/metrics/v1/get-market-timeseries This OpenAPI specification defines the GET /metrics/v1/markets/{entityIdentifier}/metrics/{datasetSlug}/time-series endpoint. It details request parameters like entityIdentifier, datasetSlug, start, and end dates, as well as the structure of successful and error responses. ```yaml paths: /metrics/v1/markets/{entityIdentifier}/metrics/{datasetSlug}/time-series: get: servers: - url: https://api.messari.io description: Messari API request: security: - title: apiKey parameters: query: {} header: X-Messari-API-Key: type: apiKey cookie: {} parameters: path: entityIdentifier: schema: - type: string required: true description: Entity ID or slug datasetSlug: schema: - type: string required: true description: Dataset slug query: start: schema: - type: string description: Time range start end: schema: - type: string description: Time range end header: {} cookie: {} body: {} response: '200': application/json: schemaArray: - type: object properties: data: allOf: - $ref: '#/components/schemas/TimeseriesData' error: allOf: - type: string metadata: allOf: - $ref: '#/components/schemas/metricsTimeseriesMetadata' requiredProperties: - data examples: example: value: data: points: - - error: metadata: granularity: 1m pointSchemas: - description: is_timestamp: true name: slug: description: Default response '400': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Bad Request '401': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Unauthorized '500': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Internal Server Error deprecated: false type: path components: schemas: TimeseriesData: properties: points: items: items: {} type: array type: array required: - points type: object metricsPointSchema: properties: description: type: string is_timestamp: type: boolean name: type: string slug: type: string required: - description - is_timestamp - name - slug type: object metricsTimeseriesMetadata: properties: granularity: enum: - 1m - 5m - 15m - 30m - 1h - 6h - 1d - 1w - 30d - 1q - 1y type: string pointSchemas: items: $ref: '#/components/schemas/metricsPointSchema' type: array required: - granularity - pointSchemas type: object ``` -------------------------------- ### Example Project Schema Source: https://docs.messari.io/api-reference/endpoints/funding/fundraising-rounds/get-v1-rounds Outlines the schema for a project, encompassing its background, category, founding date, and overview. This provides a comprehensive view of projects in the crypto space. ```json { "id": "project-abc", "name": "Example Project", "category": "DeFi", "foundedDate": "2023-11-07T05:31:56Z", "location": "San Francisco, CA", "overview": "A decentralized finance protocol.", "sector": "Technology", "tags": ["DeFi", "Blockchain"], "primaryAsset": { "id": "aSDinaTvuI8gbWludGxpZnk=", "name": "Example Token", "symbol": "EXT", "rank": 100, "sector": "Technology", "category": "Cryptocurrency", "slug": "example-token" } } ``` -------------------------------- ### List All Tracked Assets Source: https://docs.messari.io/quickstart Retrieves a list of all assets tracked by Messari. ```APIDOC ## GET /api/v1/assets ### Description Lists all assets tracked by Messari. ### Method GET ### Endpoint /api/v1/assets ### Parameters #### Query Parameters (No specific query parameters mentioned in the provided text for this endpoint) ### Request Example ```json {} ``` ### Response #### Success Response (200) - **(Response structure not detailed in the provided text)** #### Response Example ```json { "example": "(Response structure not detailed in the provided text)" } ``` ``` -------------------------------- ### GET /token-unlocks/v1/assets/{assetId}/unlocks Source: https://docs.messari.io/api-reference/endpoints/token-unlocks/get-v1-assets-assetId-unlocks Retrieves token unlock data for a specific asset. You can filter the results by specifying a start time, end time, and interval. ```APIDOC ## GET /token-unlocks/v1/assets/{assetId}/unlocks ### Description Retrieves token unlock data for a specific asset, optionally filtered by time range and interval. ### Method GET ### Endpoint `https://api.messari.io/token-unlocks/v1/assets/{assetId}/unlocks` ### Parameters #### Path Parameters - **assetId** (string) - Required - The ID of the asset. #### Query Parameters - **startTime** (string) - Optional - RFC3339 formatted start time. - **endTime** (string) - Optional - RFC3339 formatted end time. - **interval** (enum) - Optional - The time interval for the unlock data. Possible values: DAILY, WEEKLY, MONTHLY, QUARTERLY, YEARLY. #### Request Body This endpoint does not accept a request body. ### Request Example ```json { "headers": { "X-Messari-API-Key": "YOUR_API_KEY" }, "params": { "assetId": "bitcoin", "startTime": "2023-01-01T00:00:00Z", "endTime": "2023-12-31T23:59:59Z", "interval": "DAILY" } } ``` ### Response #### Success Response (200) - **data** (object) - Contains the unlock data. - **allocations** (array) - List of unlock allocations. - **allocationRecipient** (string) - The recipient of the allocation. - **dailySnapshots** (array) - Snapshots of unlocked tokens per day. - **timestamp** (string) - The timestamp of the snapshot. - **unlockedInPeriodNative** (number) - Amount unlocked in native currency. - **unlockedInPeriodUSD** (number) - Amount unlocked in USD. - **asset** (object) - Basic information about the asset. - **id** (string) - The asset ID. - **name** (string) - The asset name. - **slug** (string) - The asset slug. - **symbol** (string) - The asset symbol. - **endDate** (string) - The end date of the unlock period. - **genesisDate** (string) - The genesis date of the unlock. - **interval** (string) - The interval of the unlock data. - **projectedEndDate** (string) - The projected end date of the unlock. - **startDate** (string) - The start date of the unlock period. - **totalSnapshots** (array) - Snapshots of total unlocked tokens. - **timestamp** (string) - The timestamp of the snapshot. - **unlockedInPeriodNative** (number) - Amount unlocked in native currency. - **unlockedInPeriodUSD** (number) - Amount unlocked in USD. - **error** (string) - An error message if the request failed. #### Response Example ```json { "data": { "allocations": [ { "allocationRecipient": "0xabc...", "dailySnapshots": [ { "timestamp": "2023-11-07T05:31:56Z", "unlockedInPeriodNative": 123.45, "unlockedInPeriodUSD": 1234.56 } ] } ], "asset": { "id": "aSDinaTvuI8gbWludGxpZnk=", "name": "Bitcoin", "slug": "bitcoin", "symbol": "BTC" }, "endDate": "2024-12-31T00:00:00Z", "genesisDate": "2009-01-03T00:00:00Z", "interval": "DAILY", "projectedEndDate": "2040-01-01T00:00:00Z", "startDate": "2023-01-01T00:00:00Z", "totalSnapshots": [ { "timestamp": "2023-11-07T05:31:56Z", "unlockedInPeriodNative": 500.00, "unlockedInPeriodUSD": 5000.00 } ] }, "error": null } ``` #### Error Response - **400 Bad Request**: Returned when the request parameters are invalid. - **403 Forbidden**: Returned when the API key is invalid or missing. - **500 Internal Server Error**: Returned when there is a server-side issue. #### Error Response Example ```json { "data": null, "error": "Invalid assetId provided." } ``` ``` -------------------------------- ### Install Messari SDK-TS Source: https://docs.messari.io/examples/ai-copilot-chat Installs the latest version of the Messari SDK-TS package using npm. This is a prerequisite for using the SDK in your project. ```bash npm install @messari/sdk-ts ``` -------------------------------- ### GET /token-unlocks/v1/assets/{assetId}/events Source: https://docs.messari.io/api-reference/endpoints/token-unlocks/get-v1-assets-assetId-events Retrieves token unlock events for a specific asset. You can filter events by start time, end time, and unlock type. ```APIDOC ## GET /token-unlocks/v1/assets/{assetId}/events ### Description Retrieves token unlock events for a specific asset. You can filter events by start time, end time, and unlock type. ### Method GET ### Endpoint https://api.messari.io/token-unlocks/v1/assets/{assetId}/events ### Parameters #### Path Parameters - **assetId** (string) - Required - Asset ID to look up events by #### Query Parameters - **startTime** (string) - Optional - RFC3339 formatted start time - **endTime** (string) - Optional - RFC3339 formatted end time - **unlockType** (enum) - Optional - Filter by unlock type (CLIFF, LINEAR) #### Request Body None ### Request Example ```bash curl -X GET "https://api.messari.io/token-unlocks/v1/assets/{assetId}/events?startTime=2023-01-01T00:00:00Z&endTime=2023-12-31T23:59:59Z&unlockType=CLIFF" \ -H "X-Messari-API-Key: YOUR_API_KEY" ``` ### Response #### Success Response (200) - **data** (object) - Contains the asset information and a list of unlock events. - **error** (string) - An error message if the request failed. ##### Data Structure - **asset** (object) - **id** (string) - **name** (string) - **slug** (string) - **symbol** (string) - **unlockEvents** (array) - **timestamp** (string) - **cliff** (object, optional) - **allocations** (array) - **allocationRecipient** (string) - **amountNative** (number) - **amountUSD** (number) - **percentOfTotalAllocation** (number) - **amountNative** (number) - **amountUSD** (number) - **percentOfTotalAllocation** (number) - **dailyLinearRateChange** (object, optional) - **allocations** (array) - **allocationRecipient** (string) - **dailyAmountNative** (number) - **dailyAmountUSD** (number) - **nextDailyAmountNative** (number) - **nextDailyAmountUSD** (number) - **nextPercentOfTotalAllocation** (number) - **percentChangeOfRate** (number) - **percentOfTotalAllocation** (number) - **dailyAmountNative** (number) - **dailyAmountUSD** (number) - **nextDailyAmountNative** (number) - **nextDailyAmountUSD** (number) - **nextPercentOfTotalAllocation** (number) - **percentChangeOfRate** (number) - **percentOfTotalAllocation** (number) #### Response Example ```json { "data": { "asset": { "id": "aSDinaTvuI8gbWludGxpZnk=", "name": "Example Token", "slug": "example-token", "symbol": "EXT" }, "unlockEvents": [ { "timestamp": "2023-11-07T05:31:56Z", "cliff": { "allocations": [ { "allocationRecipient": "0x123...", "amountNative": 1000000, "amountUSD": 50000, "percentOfTotalAllocation": 0.1 } ], "amountNative": 10000000, "amountUSD": 500000, "percentOfTotalAllocation": 1 } } ] }, "error": null } ``` #### Error Responses - **400 Bad Request**: Returned if the request parameters are invalid. - **403 Forbidden**: Returned if the API key is invalid or lacks permissions. - **500 Internal Server Error**: Returned if there is a server-side issue. ``` -------------------------------- ### AI Chat Completion (OpenAI Compatible) Source: https://docs.messari.io/quickstart Generates an AI chat completion using Messari's services in an OpenAI-compatible format. ```APIDOC ## POST /ai/openai/chat/completions ### Description Generates an AI chat completion in an OpenAI-compatible format. ### Method POST ### Endpoint /ai/openai/chat/completions ### Parameters #### Request Body - **messages** (array) - Required - An array of message objects representing the conversation history. - **role** (string) - Required - The role of the author of the message (e.g., 'user', 'assistant', 'system'). - **content** (string) - Required - The content of the message. - **MultiContent** (array) - Optional - Additional content for the message. - **inlineCitations** (boolean) - Optional - Whether to include inline citations in the response. ### Request Example ```json { "messages": [ { "role": "user", "content": "What companies have both paradigm and a16z on their cap table?", "MultiContent": [{}] } ], "inlineCitations": true } ``` ### Response #### Success Response (200) - **choices** (array) - An array of chat completion choices. - **message** (object) - The message content from the AI. - **content** (string) - The generated content. #### Response Example ```json { "choices": [ { "message": { "content": "Here are some companies that have both Paradigm and Andreessen Horowitz (a16z) on their cap table..." } } ] } ``` ``` -------------------------------- ### Retrieve Asset Mindshare Timeseries Data (OpenAPI) Source: https://docs.messari.io/api-reference/endpoints/signal/asset-mindshare/get-v0-assets-assetID-time-series-mindshare-granularity This OpenAPI specification defines the GET request to retrieve an asset's mindshare timeseries data. It requires an asset ID and a granularity, and supports optional start and end times. The response includes the timeseries data points and associated metadata. ```yaml GET /signal/v0/assets/{assetID}/time-series/mindshare/{granularity} paths: path: /signal/v0/assets/{assetID}/time-series/mindshare/{granularity} method: get servers: - url: https://api.messari.io description: Messari API request: security: - title: apiKey parameters: query: {} header: X-Messari-API-Key: type: apiKey cookie: {} parameters: path: granularity: schema: - type: enum enum: - 1m - 5m - 15m - 30m - 1h - 6h - 1d - 1w - 30d - 1q - 1y required: true assetID: schema: - type: string required: true description: Asset ID, must be either a slug or UUID query: start: schema: - type: string description: Time range start. Encoded as RFC3339 or unix timestamp. end: schema: - type: string description: Time range end. Encoded as RFC3339 or unix timestamp. header: {} cookie: {} body: {} response: '200': application/json: schemaArray: - type: object properties: data: allOf: - $ref: '#/components/schemas/TimeseriesData' error: allOf: - type: string metadata: allOf: - $ref: '#/components/schemas/signalTimeseriesMetadata' requiredProperties: - data examples: example: value: data: points: - - error: metadata: granularity: 1m pointSchemas: - description: isTimestamp: true name: slug: description: Default response '400': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Bad Request '403': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Forbidden '500': application/json: schemaArray: - type: object properties: data: allOf: - {} error: allOf: - type: string requiredProperties: - data examples: example: value: data: error: description: Internal Server Error deprecated: false type: path components: schemas: TimeseriesData: properties: points: items: items: {} type: array type: array required: - points type: object signalPointSchema: properties: description: type: string isTimestamp: type: boolean name: type: string slug: type: string required: - description - isTimestamp - name - slug type: object signalTimeseriesMetadata: properties: granularity: enum: - 1m - 5m - 15m - 30m - 1h - 6h - 1d - 1w - 30d - 1q - 1y type: string pointSchemas: items: $ref: '#/components/schemas/signalPointSchema' type: array required: - granularity - pointSchemas type: object ``` -------------------------------- ### GET /funding/v1/rounds OpenAPI Specification Source: https://docs.messari.io/api-reference/endpoints/funding/fundraising-rounds/get-v1-rounds This OpenAPI specification defines the GET /funding/v1/rounds endpoint. It details the request parameters such as limit, page, fundedEntityId, investorId, type, stage, raisedAmountMax, raisedAmountMin, isTokenFunded, announcedBefore, and announcedAfter. It also describes the successful response structure, including funding round data and pagination metadata, along with an example response. ```yaml paths: /funding/v1/rounds: get: servers: - url: https://api.messari.io description: Messari API request: security: - title: apiKey parameters: query: {} header: X-Messari-API-Key: type: apiKey cookie: {} parameters: path: {} query: limit: schema: - type: integer page: schema: - type: integer fundedEntityId: schema: - type: array items: allOf: - type: string description: >- Comma-separated list of projects or organizations uuids which received funding. investorId: schema: - type: array items: allOf: - type: string description: >- Comma-separated list of investor (persons, projects, orgs) IDs who invested in the funding rounds to be retrieved. type: schema: - type: array items: allOf: - enum: - Accelerator - Debt Financing - Extended Pre Seed - Extended Seed - Extended Series A - Extended Series B - Extended Series C - Extended Series D - Grant - ICO - IPO - Post IPO - Post IPO Debt - Pre Seed - Pre Series A - Pre Series B - Private Token Sale - Public Token Sale - Seed - Series A - Series B - Series C - Series D - Series E - Series F - Series G - Series H - Strategic - Treasury Diversification - Undisclosed type: string description: Comma-separated list of funding round types to filter by. stage: schema: - type: array items: allOf: - enum: - Seed - Early Stage - Late Stage - Public Equity Offering - Post Public Equity - Miscellaneous type: string description: Comma-separated list of funding round stages to filter by. raisedAmountMax: schema: - type: number description: >- Filter by maximum amount raised in USD. Will return rounds which have raised less than the specified amount. raisedAmountMin: schema: - type: number description: >- Filter by minimum amount raised in USD. Will return rounds which have raised more than the specified amount. isTokenFunded: schema: - type: boolean description: Filter by rounds that were funded with tokens. announcedBefore: schema: - type: string description: Filter by rounds announced before the specified date. format: date-time announcedAfter: schema: - type: string description: Filter by rounds announced after the specified date. format: date-time header: {} cookie: {} body: {} response: '200': application/json: schemaArray: - type: object properties: data: allOf: - items: $ref: '#/components/schemas/FundingRound' type: array error: allOf: - type: string metadata: allOf: - $ref: '#/components/schemas/Pagination' requiredProperties: - data examples: example: value: data: - amountRaisedUSD: 123 announcementDate: '2023-11-07T05:31:56Z' announcements: - url: fundedEntity: id: name: organization: category: description: ``` -------------------------------- ### GET /metrics/v2/assets/{entityIdentifier}/metrics/{datasetSlug}/time-series Source: https://docs.messari.io/api-reference/endpoints/metrics/v2/assets/get-asset-timeseries Retrieves timeseries data for a specific asset and dataset. You can filter the data by specifying a start and end time. ```APIDOC ## GET /metrics/v2/assets/{entityIdentifier}/metrics/{datasetSlug}/time-series ### Description Retrieves timeseries data for a specific asset and dataset. You can filter the data by specifying a start and end time. ### Method GET ### Endpoint https://api.messari.io/metrics/v2/assets/{entityIdentifier}/metrics/{datasetSlug}/time-series ### Parameters #### Path Parameters - **entityIdentifier** (string) - Required - Entity ID or slug - **datasetSlug** (string) - Required - Dataset slug #### Query Parameters - **start** (string) - Optional - Time range start - **end** (string) - Optional - Time range end #### Request Body This endpoint does not accept a request body. ### Request Example ```json { "example": "https://api.messari.io/v2/assets/bitcoin/metrics/price/time-series?start=2023-01-01&end=2023-01-31" } ``` ### Response #### Success Response (200) - **data** (object) - Contains the timeseries data points and metadata. - **points** (array of arrays) - Array of data points, where each point is an array of values corresponding to the `pointSchemas`. - **error** (string) - Error message if any. - **metadata** (object) - Metadata about the timeseries data. - **granularity** (string) - The time granularity of the data (e.g., "1m", "1d"). - **pointSchemas** (array of objects) - Describes the structure of each data point. - **description** (string) - Description of the data point. - **is_timestamp** (boolean) - Indicates if the field is a timestamp. - **name** (string) - Name of the data point. - **slug** (string) - Slug of the data point. #### Response Example ```json { "data": { "points": [ [ 1672531200000, 30000.50, 10000000000.0 ], [ 1672617600000, 31000.75, 10500000000.0 ] ], "error": null, "metadata": { "granularity": "1d", "pointSchemas": [ { "description": "Timestamp of the data point", "is_timestamp": true, "name": "Timestamp", "slug": "timestamp" }, { "description": "Price of the asset", "is_timestamp": false, "name": "Price", "slug": "price" }, { "description": "Market cap of the asset", "is_timestamp": false, "name": "Market Cap", "slug": "market_cap" } ] } } } ``` #### Error Response (400) - **data** (any) - Empty or error-related data. - **error** (string) - Description of the error. #### Error Response (401) - **data** (any) - Empty or error-related data. - **error** (string) - Description of the error (e.g., invalid API key). #### Error Response (500) - **data** (any) - Empty or error-related data. - **error** (string) - Description of the server error. ``` -------------------------------- ### Instantiate Messari Client with @messari/sdk-ts Source: https://docs.messari.io/examples/signals-example Initialize the Messari SDK client using your API key. The API key can be provided during initialization or set as an environment variable. This client is used to interact with the Messari API endpoints. ```typescript import { MessariSDK } from "@messari/sdk-ts"; const apiKey = process.env.MESSARI_API_KEY; const client = new MessariSDK(apiKey); ```