Share feedback, ideas and get community help

A
André
Offline, last seen 3 months ago
Joined September 13, 2024
Hi,

In a bot I need to execute the Javascript "window.location.hostname". It is possible to do it in a TypeBot variable?

Thanks.
2 comments
A
B
Hi,

I'm building a chatbot that uses an LLM. I've been using together.ai. The requests to the API due to the nature of the LLM's sometimes takes more than 10 seconds.

I've been investigating the code: https://github.com/baptisteArno/typebot.io/blob/main/packages/bot-engine/blocks/integrations/webhook/executeWebhookBlock.ts

It seems that this problem will be handle in the future. Anybody know when will be possible to adjust the timeouts?

Best Regards,
André.
6 comments
B
L
A
Hi, I'm struggling to set an Javascript array variable in Typebot. The context is the following. I need to generate an array of messages to send to an API via Webhook.

The Webhook have the following body:

{
"model": "some-model",
"max_tokens": 1024,
"messages": {{messages_hist}},
"stream": false
}

I need to pass in "messages" the following Array:

[{"role": "system","content": "some system message"},{"role": "user","content": "some user message"}]

To achieve this I'm trying to 'Set variable' in the Typebot. A 'Custom' variable by the way, with this:

[{"role": "system","content": "some system message"},{"role": "user","content": "some user message"}]

The problem is that the Webhook does not work because(I think) what's inside the JS Array is being interpreted as a regular string:

["{"role":"system","content":"some system message"}","{"role":"user","content":"some user message"}"]

Any clues on how to handle Array variables in Typebot?
10 comments
B
I
A