What you do need to do is probably to jsonDecoded it.
okay
if (kDebugMode) {
final decoded = jsonDecode(response.toString());
print(decoded.toString());
}
})```
no result
this is on cloud function code:
'areDevelopersAwesome': true,
});```
Do this
functions.createExecution(
functionId: '[FUNCTION_ID]',
).then((response) {
if (kDebugMode) {
print(jsonDecode(response.response));
}
};
worked, thanks
but at times, changes on cloud function does not reflect even when build is completed on console
what is the solution?
What you mean? You're deploying a new function and getting back the old one?
got this: flutter: {areDevelopersAwesome: true}
and I changed the respinse on cloud
yes
What you get when you're executing it on the cloud?
@dammy When you execute a function from your client app, it returns an Execution object: https://appwrite.io/docs/models/execution
If you want to get the response of the function, you can do something like this:
const promise = await functions.createExecution('[FUNCTION_ID]');
const response = promise.response;
Keep in mind that promise.response will be a string, that you will need to parse.
got this:
areDevelopersAwesome: true
And I changed it to this:
'status': "refund"
did you redeploy?
How have you deployed the new version of the function?
I appreciate, sorted, am now getting response by decoding it
yes, appwrite deploy function
function ID is also accurate
alright perfect
thanks
? Which functions would you like to deploy? automated_mobile_data (my_function_ID)
ℹ Info Deploying function automated_mobile_data ( my_function_ID )
ℹ Info Ignoring files using configuration from appwrite.json
✓ Success Deployed automated_mobile_data ( my_function_ID)
✓ Success Deployed 1 functions```
I deliberately deleted the function from console and do a fresh deployment, same issue
It just reflected, took sooooo long
I noticed that this issue is consistent with appwrite cloud
what's the use-case?
Recommended threads
- ClientException with SocketException: Cl...
hi <@564158268319203348> i have noticed this 500 status code in my function requests, it seems its not able to connect to the internet in the function as reque...
- NEW ERROR Invalid document structure: At...
Error: ```AppwriteException: document_invalid_structure, Invalid document structure: Attribute "pb.kmsgxPkgInfo.id_info" must be an array (400)``` I’m encounter...
- Issues with executor in Appwrite 1.9.0
Hi, I’ve recently did a fresh install of appwrite 1.9.0 self hosted and when I run a function, it just waits indefinite This is the error from the log: [Er...