Closed Jamesllllllllll closed 11 months ago
I am not 100%, but I don't think the gadget api client calls this route. I mainly had this route up for testing. How are you currently uploading documents?
We've concluded that the api client being used in the frontend bypasses the HTTP route. We keep the HTTP route to test nonetheless.
I'm looking at
/routes/document/POST.js
This passes the file along to
/document/actions/create
however I don't see the actual file object:Does this just create a string of the
name
,role
andassistantId
from the body of the request? I might be missing where the file is here.Right now on the Front End I'm directly calling
api.document.create
and it correctly adds records. When I get the return value, I can pass the file'sid
to the/routes/assistants
POST request and include an array of fileid
s for the creation of the assistant.