1
0
Fork 0
mirror of synced 2024-06-16 09:44:50 +12:00
appwrite/app/sdks/server-nodejs/docs/examples/functions/update.md

19 lines
432 B
Markdown
Raw Normal View History

2020-05-11 08:13:51 +12:00
const sdk = require('node-appwrite');
// Init SDK
let client = new sdk.Client();
let functions = new sdk.Functions(client);
client
.setProject('5df5acd0d48c2') // Your project ID
.setKey('919c2d18fb5d4...a2ae413da83346ad2') // Your secret API key
;
2020-05-11 08:44:28 +12:00
let promise = functions.update('[FUNCTION_ID]', '[NAME]');
2020-05-11 08:13:51 +12:00
promise.then(function (response) {
console.log(response);
}, function (error) {
console.log(error);
});