Kotlin - Document payload missing when creating document with null values
- 0
- Self Hosted
- Databases
I have a collection with two attributes, and when I create a document with the Kotlin SDK with both of them set to null, i get the error AppwriteException: The document payload is missing.
Hi
Can you show me the code you have been using to make the document? and also the version of Appwrite
val appwriteClient = Client()
.setEndpoint(env("APPWRITE_ENDPOINT"))
.setProject(env("APPWRITE_PROJECT_ID"))
.setKey(env("APPWRITE_API_KEY"))
val databases = Databases(appwriteClient)
databases.createDocument(
databaseId = env("APPWRITE_CONFIG_DATABASE_ID"),
collectionId = env("APPWRITE_CONFIG_COLLECTION_ID"),
documentId = serverId.toString(),
data = mapOf(
"admin_alert_channel" to null,
"admin_role_id" to null
)
)
sorry i fell asleep lol
sdk version is 2.0.0
huh it's only when both values are null
if i set one to a random integer it works but when both are null, i get the error
is there any way i can fix this on my side or is it an appwrite thing?
this is weird
i can agree with that lol
ill check this and let you know once
tysm! do you have any estimate on how long that'll be?
Recommended threads
- Appwrite console is too heavy
The Appwrite console is too heavy And all of my services broken Any support , please
- Usage of the new Client() and dealing wi...
Hey guys, just a quick one - we had some web traffic the other day and it ended up bombing out - To put in perspective of how the app works, we have a Nuxt Ap...
- [Beginner] CLI --queries Syntax Error & ...
Hi everyone! I am a beginner with Appwrite and trying to use the CLI, but I'm stuck with a syntax error. Any guidance would be greatly appreciated! 🙏 **Enviro...