if trying to print payload then its giving error else its working fine, An internal curl error has occurred within the executor! Error Msg:
Operation timed out
Please share your code
why payload is not printing ,
//assigning
final payload = !req.payload?.isEmpty ? req.payload : 'No payload provided. Add custom data when executing function.';
//printing
print(payload["hallelujah"]);
and here is custom data or providing payload to appwrite console```{ 'hallelujah':[ { 'image': 'image', 'productName': 'love you jesus ', 'productUnit': 'productUnit', 'barcode': 55558888, 'id': " d5454a", 'sellingPrice': 44.0, 'totalQuantity': 100.0, 'quantity': 1.0 } ]
}```
What doesn't this work?
final payload = "I'm a string";
print(payload["key"]);
yes, this does not work some time , its saying "type '_OneByteString' is not a subtype of type 'int' of 'index'" and if execution is delaying then it just says An internal curl error has occurred within the executor! Error Msg:
Operation timed out
You'll see that operation timed out if your function throws an exception
You need to send a valid JSON string for the data. Single quotes are not valid in JSON.
Then, you need to use jsonDecode() to convert the JSON string to a map
now its working , thanks @Steven
Recommended threads
- router_deployment_not_found
I updated my function a few times and now i am getting the error: router_deployment_not_found I even reverted back to my original code but i am still getting th...
- 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...