Create file is listing files instead of creating the file, this inside an Appwrite function on 1.8.1
- 0
- Self Hosted
- Functions
- Storage
This is a bit strange but, I cannot create files from within a funcion. I have tested with latest SDKs versions of node and python, both instead of creating the file, return the list of files that are stored on the bucket.
result = await storage.createFile({
bucketId: OUTPUT_BUCKET_ID,
fileId: outputFileId,
file: InputFile.fromPath(tempPath, "certificate.pdf")
});
log(`createFile: ${JSON.stringify(result)}`);
createFile: {"total":3,"files":[{"$id":"69262f31001d4ecdf886","bucketId":"b_internal","$createdAt":"2025-11-25T22:35:29.899+00:00","$updatedAt":"2025-11-25T22:35:29.899+00:00","$permissions":["read(\"user:67086926000a44243115\")","update(\"user:67086926000a44243115\")","delete(\"user:67086926000a44243115\")"],"name":"university.png","signature":"561b1e77208ff23b5557b89ff8ee8ae5","mimeType":"image/png","sizeOriginal":27818,"chunksTotal":1,"chunksUploaded":1},{"$id":"69262f3500361d4be8dd","bucketId":"b_internal","$createdAt":"2025-11-25T22:35:34.283+00:00","$updatedAt":"2025-11-25T22:35:34.283+00:00","$permissions":["read(\"user:67086926000a44243115\")","update(\"user:67086926000a44243115\")","delete(\"user:67086926000a44243115\")"],"name":"signature.png","signature":"e36241b01aaa5cf646fc84cdee2c7307","mimeType":"image/png","sizeOriginal":10652,"chunksTotal":1,"chunksUploaded":1},{"$id":"6926310a0011858de642","bucketId":"b_internal","$createdAt":"2025-11-25T22:43:22.732+00:00","$updatedAt":"2025-11-25T22:43:22.732+00:00","$permissions":["read(\"user:67086926000a44243115\")","update(\"user:67086926000a44243115\")","delete(\"user:67086926000a44243115\")"],"name":"logo.png","signature":"64182af861a6f03318517c9de291613b","mimeType":"image/png","sizeOriginal":26408,"chunksTotal":1,"chunksUploaded":1}]}
Any help will be really appreciated.
Bump!
Probably downdrading a minor version will be better if this is actually a bug.
Thanks for your answer, but its weird, I have tested on my local machine and it worked, but within the appwrite functions it just does like I said. Pretty weird.
Recommended threads
- OAuth provider credentials reverting [CR...
Hi team, I’m experiencing repeated OAuth configuration resets in my Appwrite project. ## Issue 1 – Google OAuth credentials reverting * I configure my own Goog...
- Unable to connect the git repo with appw...
I am trying to connect my existing repo with the appwrite functions. I have 2 functions in the same repo, and i was able to execute those through cli and its vi...
- Hey everyone! I'm trying to self-host th...
Hey everyone! I'm trying to self-host the latest Appwrite version (1.8.1) on Coolify. Which docker-compose.yml file should I use from their repo? Can someone he...