I am following the assistant example for how to handle functions.
before making this call I have ensured that threadId
, runId
and tool_call_id
are all correct (by calling the respective endpoints and getting the data of the current run).
run = openai.beta.threads.runs.submitToolOutputs(
threadId,
runId,
{
tool_outputs: [
{
"tool_call_id": tool_call_id,
"output": result
}
]
}
)
When calling the below function all these variables are correct. However there is an internal exception happening:
node_modules/openai/error.mjs:48
return new NotFoundError(status, error, message, headers);
^
NotFoundError: 404 No run found with id 'undefined'.
at APIError.generate (node_modules/openai/error.mjs:48:20)
at OpenAI.makeStatusError (node_modules/openai/core.mjs:244:25)
at OpenAI.makeRequest (node_modules/openai/core.mjs:283:30)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)