mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
docs(sdks): 0.11.0
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.create_recovery(email: 'email@example.com', url: 'https://example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.create_verification(url: 'https://example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.delete_session(session_id: '[SESSION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.delete_sessions();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.delete();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.get_logs();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.get_prefs();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.get_session(session_id: '[SESSION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.get_sessions();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.get();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_email(email: 'email@example.com', password: 'password');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_name(name: '[NAME]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_password(password: 'password');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_prefs(prefs: {});
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_recovery(user_id: '[USER_ID]', secret: '[SECRET]', password: 'password', password_again: 'password');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
account = Appwrite::Account.new(client);
|
||||
|
||||
response = account.update_verification(user_id: '[USER_ID]', secret: '[SECRET]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_browser(code: 'aa');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_credit_card(code: 'amex');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_favicon(url: 'https://example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_flag(code: 'af');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_image(url: 'https://example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_initials();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
avatars = Appwrite::Avatars.new(client);
|
||||
|
||||
response = avatars.get_qr(text: '[TEXT]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.create_collection(name: '[NAME]', read: [], write: [], rules: []);
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.create_document(collection_id: '[COLLECTION_ID]', data: {});
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.delete_collection(collection_id: '[COLLECTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.delete_document(collection_id: '[COLLECTION_ID]', document_id: '[DOCUMENT_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.get_collection(collection_id: '[COLLECTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.get_document(collection_id: '[COLLECTION_ID]', document_id: '[DOCUMENT_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.list_collections();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.list_documents(collection_id: '[COLLECTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.update_collection(collection_id: '[COLLECTION_ID]', name: '[NAME]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
database = Appwrite::Database.new(client);
|
||||
|
||||
response = database.update_document(collection_id: '[COLLECTION_ID]', document_id: '[DOCUMENT_ID]', data: {});
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.create_execution(function_id: '[FUNCTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.create_tag(function_id: '[FUNCTION_ID]', command: '[COMMAND]', code: Appwrite::File.new());
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.create(name: '[NAME]', execute: [], runtime: 'dotnet-5.0');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.delete_tag(function_id: '[FUNCTION_ID]', tag_id: '[TAG_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.delete(function_id: '[FUNCTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.get_execution(function_id: '[FUNCTION_ID]', execution_id: '[EXECUTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.get_tag(function_id: '[FUNCTION_ID]', tag_id: '[TAG_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.get(function_id: '[FUNCTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.list_executions(function_id: '[FUNCTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.list_tags(function_id: '[FUNCTION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.list();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.update_tag(function_id: '[FUNCTION_ID]', tag: '[TAG]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
functions = Appwrite::Functions.new(client);
|
||||
|
||||
response = functions.update(function_id: '[FUNCTION_ID]', name: '[NAME]', execute: []);
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_anti_virus();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_cache();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_db();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_certificates();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_functions();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_logs();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_tasks();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_usage();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_queue_webhooks();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_storage_local();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get_time();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
health = Appwrite::Health.new(client);
|
||||
|
||||
response = health.get();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_continents();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_countries_eu();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_countries_phones();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_countries();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_currencies();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get_languages();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
locale = Appwrite::Locale.new(client);
|
||||
|
||||
response = locale.get();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.create_file(file: Appwrite::File.new());
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.delete_file(file_id: '[FILE_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.get_file_download(file_id: '[FILE_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.get_file_preview(file_id: '[FILE_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.get_file_view(file_id: '[FILE_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.get_file(file_id: '[FILE_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.list_files();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
storage = Appwrite::Storage.new(client);
|
||||
|
||||
response = storage.update_file(file_id: '[FILE_ID]', read: [], write: []);
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.create_membership(team_id: '[TEAM_ID]', email: 'email@example.com', roles: [], url: 'https://example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.create(name: '[NAME]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.delete_membership(team_id: '[TEAM_ID]', membership_id: '[MEMBERSHIP_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.delete(team_id: '[TEAM_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.get_memberships(team_id: '[TEAM_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.get(team_id: '[TEAM_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.list();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.update_membership_roles(team_id: '[TEAM_ID]', membership_id: '[MEMBERSHIP_ID]', roles: []);
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_jwt('eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ...') # Your secret JSON Web Token
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.update_membership_status(team_id: '[TEAM_ID]', membership_id: '[MEMBERSHIP_ID]', user_id: '[USER_ID]', secret: '[SECRET]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
teams = Appwrite::Teams.new(client);
|
||||
|
||||
response = teams.update(team_id: '[TEAM_ID]', name: '[NAME]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.create(email: 'email@example.com', password: 'password');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.delete_session(user_id: '[USER_ID]', session_id: '[SESSION_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.delete_sessions(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.delete(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.get_logs(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.get_prefs(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.get_sessions(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.get(user_id: '[USER_ID]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.list();
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_email(user_id: '[USER_ID]', email: 'email@example.com');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_name(user_id: '[USER_ID]', name: '[NAME]');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_password(user_id: '[USER_ID]', password: 'password');
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_prefs(user_id: '[USER_ID]', prefs: {});
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_status(user_id: '[USER_ID]', status: 1);
|
||||
|
||||
puts response
|
||||
@@ -0,0 +1,15 @@
|
||||
require 'appwrite'
|
||||
|
||||
client = Appwrite::Client.new()
|
||||
|
||||
client
|
||||
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
|
||||
.set_project('5df5acd0d48c2') # Your project ID
|
||||
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
|
||||
;
|
||||
|
||||
users = Appwrite::Users.new(client);
|
||||
|
||||
response = users.update_verification(user_id: '[USER_ID]', email_verification: false);
|
||||
|
||||
puts response
|
||||
Reference in New Issue
Block a user