Telegram /test endpoint

Hey all,

I’m using the Telegram node to try and send an invoice. Because I’m going to be taking dummy payments to start testing everything I want to use the /test endpoint; more info here: Telegram Bot Features
The URL format for the endpoint is https://api.telegram.org/bot<token>/test/METHOD_NAME
I’d rather not implement all the node functionality in HTTP requests for testing.

Does anyone know how to use the test endpoint within n8n?

Information on your n8n setup

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

I’m not sure I quite get you?

I’ve created a new Telegram bot in their testing environment, and to interact with this bot from n8n (e.g. get the messages and pass to further functions/nodes), I need the Base URL to be the below:

So, the default Base URL is https://api.telegram.org, which interacts with Telegram bots within the production Telegram environment.

To test payment features, without having to spend real money, you can use their test Telegram environment, that needs an additional /test before the method:


Source: Telegram Bot Features
The bot has been created within the test environment, however, I’m unable to interact with it from n8n, as I’m unable to use the correct base URL.
By the sounds of it, there is no functionality within the Telegram n8n node to use the /test endpoint?

To be clear, I’m fine with using n8n otherwise, I’m just unable to locate this one feature - I’d rather not reinvent the wheel with http requests if there’s a button/node option I’ve managed to miss, or a way to alter the base URL.

As far as I know, that isn’t supported. Here’s the Telegram API Credential Source code.

Here’s where baseUrl gets used to assemble the API URI.

(Sorry for the confusion between n8n test mode and Telegram test environment)… deleting the previous post.

2 Likes

That’s a shame, it would be a small tweak to make, add an option to use the /test endpoint, and update the URL format.
I’m a little out of my depth adding that change…

I agree (with the shame part… I know nothing about your depth). If you have a moment, isolate the issue and the ask as a Feature Request Post

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