examples and changelog

This commit is contained in:
Chirag Aggarwal
2026-02-02 18:04:02 +05:30
parent eb97a0e9b2
commit 02c92d95b7
236 changed files with 4160 additions and 12 deletions
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.create_longtext_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.create_mediumtext_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.create_text_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,19 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.create_varchar_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
size = 1,
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.update_longtext_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.update_mediumtext_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.update_text_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,19 @@
from appwrite.client import Client
from appwrite.services.databases import Databases
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
databases = Databases(client)
result = databases.update_varchar_attribute(
database_id = '<DATABASE_ID>',
collection_id = '<COLLECTION_ID>',
key = '',
required = False,
default = '<DEFAULT>',
size = 1, # optional
new_key = '' # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.create_longtext_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.create_mediumtext_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.create_text_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,19 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.create_varchar_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
size = 1,
required = False,
default = '<DEFAULT>', # optional
array = False # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.update_longtext_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.update_mediumtext_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,18 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.update_text_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>',
new_key = '' # optional
)
@@ -0,0 +1,19 @@
from appwrite.client import Client
from appwrite.services.tables_db import TablesDB
client = Client()
client.set_endpoint('https://<REGION>.cloud.appwrite.io/v1') # Your API Endpoint
client.set_project('<YOUR_PROJECT_ID>') # Your project ID
client.set_key('<YOUR_API_KEY>') # Your secret API key
tables_db = TablesDB(client)
result = tables_db.update_varchar_column(
database_id = '<DATABASE_ID>',
table_id = '<TABLE_ID>',
key = '',
required = False,
default = '<DEFAULT>',
size = 1, # optional
new_key = '' # optional
)