Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

84
Vistas
sendMessage telegam telegraf

How do I indent a message in a fetch request? For clarity, I will attach code and result. I'm using telegraf lib for telegram on JavaScript.

fetch(
              `https://api.telegram.org/bot${ENV.TELEGRAM_TOKEN}/sendMessage?chat_id=${messages.chatId}&text=🆙 LEVEL UP! 🆙

Your bonus level is now gold🥇 You can see what privileges are available to you by clicking on the command /bonus`,
              {
                method: 'GET',
                headers: {
                  'Content-Type': 'application/json',
                  'Accept': 'application/json',
                },
              },
            );

And I get in bot:

🆙 LEVEL UP! 🆙 Your bonus level is now gold🥇 You can see what privileges are available to you by clicking on the command /bonus

But I'm expected to see:

🆙 LEVEL UP! 🆙

Your bonus level is now gold🥇 You can see what privileges are available to you by clicking on the command /bonus

How can I indent between messages? Help me please

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda