Skip to content

Commit 18aa984

Browse files
authored
Merge pull request #31 from appwrite/dev
Add time between queries
2 parents a78e3d2 + 709039e commit 18aa984

27 files changed

+1544
-18
lines changed

docs/examples/account/update-prefs.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,9 @@ const client = new Client()
88
const account = new Account(client);
99

1010
const response = await account.updatePrefs({
11-
prefs: {}
11+
prefs: {
12+
"language": "en",
13+
"timezone": "UTC",
14+
"darkTheme": true
15+
}
1216
});

docs/examples/databases/create-document.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,12 @@ const response = await databases.createDocument({
1111
databaseId: '<DATABASE_ID>',
1212
collectionId: '<COLLECTION_ID>',
1313
documentId: '<DOCUMENT_ID>',
14-
data: {},
14+
data: {
15+
"username": "walter.obrien",
16+
"email": "walter.obrien@example.com",
17+
"fullName": "Walter O'Brien",
18+
"age": 30,
19+
"isAdmin": false
20+
},
1521
permissions: ["read("any")"] // optional
1622
});
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.createLineAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]] // optional
16+
});
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.createPointAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]] // optional
16+
});
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.createPolygonAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]] // optional
16+
});
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.updateLineAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]], // optional
16+
newKey: '' // optional
17+
});
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.updatePointAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]], // optional
16+
newKey: '' // optional
17+
});
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Client, Databases } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const databases = new Databases(client);
9+
10+
const response = await databases.updatePolygonAttribute({
11+
databaseId: '<DATABASE_ID>',
12+
collectionId: '<COLLECTION_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]], // optional
16+
newKey: '' // optional
17+
});
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Client, TablesDB } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const tablesDB = new TablesDB(client);
9+
10+
const response = await tablesDB.createLineColumn({
11+
databaseId: '<DATABASE_ID>',
12+
tableId: '<TABLE_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]] // optional
16+
});
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Client, TablesDB } from "https://deno.land/x/appwrite/mod.ts";
2+
3+
const client = new Client()
4+
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('<YOUR_PROJECT_ID>') // Your project ID
6+
.setKey('<YOUR_API_KEY>'); // Your secret API key
7+
8+
const tablesDB = new TablesDB(client);
9+
10+
const response = await tablesDB.createPointColumn({
11+
databaseId: '<DATABASE_ID>',
12+
tableId: '<TABLE_ID>',
13+
key: '',
14+
required: false,
15+
default: [[1,2], [3, 4]] // optional
16+
});

0 commit comments

Comments
 (0)