Blocks tool input not parsing variables
# support
v
message has been deleted
@Cayan Hello! How can I assist you with VAPI today? If you have any questions or need support with voice development, feel free to ask!
You can continue this conversation by mentioning me in the message.
c
I still need help
@Shubham Bajaj @krish450
could you help me?
I also tried in the query string but it is not parsing either
k
Following up here @Shubham Bajaj im getting the same error. Input variables I pass into tool block are not being parsed into the content of the variable when i send request. The request is receiving the variable name only. I can see in logs the variable was populated with info prior to going to tool step so am also lost with how to send request with information i captured in call
@Vapi
v
@krish450 I'm here to help! It sounds like you're experiencing an issue with passing variables into a tool within VAPI. To better assist you, could you please provide me with more details about the specific tool you're using and the exact nature of the problem? If you could share the code snippet or the way you're trying to pass the variables, that would be very helpful in diagnosing the issue.
k
blocks
s
Hey @Cayan @krish450 To help track down this issue, could you share: - The call ID - When exactly this happened (the timestamp) - What response you expected to get - What response you actually got instead This would really help me figure out what went wrong!
c
I'll reproduce it now and get a fresh one!
neither the argument or the query string was parsed:
Copy code
"message": {
    "timestamp": 1734016127096,
    "type": "tool-calls",
    "tool_calls": [
      {
        "type": "function",
        "function": {
          "name": "tool",
          "parameters": {
            "type": "object",
            "required": [
              "patientId",
              "slotId"
            ],
            "properties": {
              "slot_id": {
                "type": "string"
              },
              "patient_id": {
                "type": "string"
              }
            }
          },
          "arguments": {
            "slot_id": "{{slot_options.output.slot_id}}",
            "patient_id": "1"
          }
        },
        "id": "8af7435a-f401-4a8d-8b4a-9e9af2e08d3d"
      }
    ],
Copy code
Started At
2024-12-12 15:08:47.096

.
Finished At
2024-12-12 15:08:47.453

.
Duration
0.36

.
URL
https://.../voice-assistant/schedule?slotId={{conversation_1.output.slot_id}}

.
Path
/voice-assistant/schedule

.
Query
?slotId={{conversation_1.output.slot_id}}

.
Method
POST
And the information is available:
Copy code
{
          "role": "assistant",
          "tool_calls": [
            {
              "id": "call_DtXw9k6bD7pneyrZx0A8S6th",
              "type": "function",
              "function": {
                "name": "getConversationOutput",
                "arguments": "{\"slot_id\": \"1212968\"}"
              }
            }
          ]
        },
k
@Shubham Bajaj let us know if you need anything else
v
Comment here just to track progress, have same issue
s
@Cayan@krish450 @vaniacrunch We're re-writing the blocks, and they're not ready for production or development yet. I suggest using assistants(prompt) instead.