HTTP Request: get tokenprice from coinmarketcap api (invalid url)

Describe the problem/error/question

New to the platform. Setting up an AI agent that looks up the token price using the Coinmarketcap API. I keep getting the error “invalid url”.

What is the error message (if any)?

Invalid url.

Please share your workflow

Used custom auth with json:
{
“headers”: {
“X-CMC_PRO_API_KEY”: “KEY”
}
}

and tried header auth with name (header) and value (api_key).

Workflow below:

Share the output returned by the last node

Node type

@n8n/n8n-nodes-langchain.toolHttpRequest

Node version

1.1 (Latest)

n8n version

1.76.1 (Cloud)

Time

29/01/2025, 21:25:19

Stack trace

NodeApiError: Invalid URL at RoutingNode.runNode (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/routing-node.js:159:23) at WorkflowExecute.runNode (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:683:23) at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:890:51 at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:1224:20

Information on your n8n setup

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

You’re using their v1 api, which is deprecated. I’d recommend to switch to v2. If the problem remains, verify that the provided URL works with a tool like postman - this could be an issue with the request itself, or the symbol you’re using.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.