react-native-appwrite 0.16.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/dist/cjs/sdk.js +707 -31
  3. package/dist/cjs/sdk.js.map +1 -1
  4. package/dist/esm/sdk.js +707 -32
  5. package/dist/esm/sdk.js.map +1 -1
  6. package/docs/examples/account/list-identities.md +2 -1
  7. package/docs/examples/account/list-logs.md +2 -1
  8. package/docs/examples/databases/create-document.md +3 -2
  9. package/docs/examples/databases/create-operations.md +24 -0
  10. package/docs/examples/databases/create-transaction.md +13 -0
  11. package/docs/examples/databases/decrement-document-attribute.md +2 -1
  12. package/docs/examples/databases/delete-document.md +2 -1
  13. package/docs/examples/databases/delete-transaction.md +13 -0
  14. package/docs/examples/databases/get-document.md +2 -1
  15. package/docs/examples/databases/get-transaction.md +13 -0
  16. package/docs/examples/databases/increment-document-attribute.md +2 -1
  17. package/docs/examples/databases/list-documents.md +3 -1
  18. package/docs/examples/databases/list-transactions.md +13 -0
  19. package/docs/examples/databases/update-document.md +3 -2
  20. package/docs/examples/databases/update-transaction.md +15 -0
  21. package/docs/examples/databases/upsert-document.md +3 -2
  22. package/docs/examples/functions/list-executions.md +2 -1
  23. package/docs/examples/storage/create-file.md +1 -1
  24. package/docs/examples/storage/list-files.md +2 -1
  25. package/docs/examples/storage/update-file.md +1 -1
  26. package/docs/examples/tablesdb/create-operations.md +24 -0
  27. package/docs/examples/tablesdb/create-row.md +3 -2
  28. package/docs/examples/tablesdb/create-transaction.md +13 -0
  29. package/docs/examples/tablesdb/decrement-row-column.md +2 -1
  30. package/docs/examples/tablesdb/delete-row.md +2 -1
  31. package/docs/examples/tablesdb/delete-transaction.md +13 -0
  32. package/docs/examples/tablesdb/get-row.md +2 -1
  33. package/docs/examples/tablesdb/get-transaction.md +13 -0
  34. package/docs/examples/tablesdb/increment-row-column.md +2 -1
  35. package/docs/examples/tablesdb/list-rows.md +3 -1
  36. package/docs/examples/tablesdb/list-transactions.md +13 -0
  37. package/docs/examples/tablesdb/update-row.md +3 -2
  38. package/docs/examples/tablesdb/update-transaction.md +15 -0
  39. package/docs/examples/tablesdb/upsert-row.md +3 -2
  40. package/docs/examples/teams/list-memberships.md +2 -1
  41. package/docs/examples/teams/list.md +2 -1
  42. package/package.json +2 -3
  43. package/src/client.ts +1 -1
  44. package/src/enums/execution-status.ts +1 -0
  45. package/src/index.ts +3 -0
  46. package/src/models.ts +45 -1
  47. package/src/operator.ts +308 -0
  48. package/src/query.ts +6 -6
  49. package/src/services/account.ts +30 -12
  50. package/src/services/databases.ts +422 -56
  51. package/src/services/functions.ts +15 -7
  52. package/src/services/storage.ts +15 -7
  53. package/src/services/tables-db.ts +422 -56
  54. package/src/services/teams.ts +30 -14
  55. package/types/enums/execution-status.d.ts +2 -1
  56. package/types/index.d.ts +3 -0
  57. package/types/models.d.ts +43 -1
  58. package/types/operator.d.ts +180 -0
  59. package/types/services/account.d.ts +8 -2
  60. package/types/services/databases.d.ts +158 -8
  61. package/types/services/functions.d.ts +4 -1
  62. package/types/services/storage.d.ts +4 -1
  63. package/types/services/tables-db.d.ts +158 -8
  64. package/types/services/teams.d.ts +8 -2
@@ -7,7 +7,8 @@ const client = new Client()
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.listIdentities({
10
- queries: [] // optional
10
+ queries: [], // optional
11
+ total: false // optional
11
12
  });
12
13
 
13
14
  console.log(result);
@@ -7,7 +7,8 @@ const client = new Client()
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.listLogs({
10
- queries: [] // optional
10
+ queries: [], // optional
11
+ total: false // optional
11
12
  });
12
13
 
13
14
  console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, Databases } from "react-native-appwrite";
1
+ import { Client, Databases, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -17,7 +17,8 @@ const result = await databases.createDocument({
17
17
  "age": 30,
18
18
  "isAdmin": false
19
19
  },
20
- permissions: ["read("any")"] // optional
20
+ permissions: ["read("any")"], // optional
21
+ transactionId: '<TRANSACTION_ID>' // optional
21
22
  });
22
23
 
23
24
  console.log(result);
@@ -0,0 +1,24 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.createOperations({
10
+ transactionId: '<TRANSACTION_ID>',
11
+ operations: [
12
+ {
13
+ "action": "create",
14
+ "databaseId": "<DATABASE_ID>",
15
+ "collectionId": "<COLLECTION_ID>",
16
+ "documentId": "<DOCUMENT_ID>",
17
+ "data": {
18
+ "name": "Walter O'Brien"
19
+ }
20
+ }
21
+ ] // optional
22
+ });
23
+
24
+ console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.createTransaction({
10
+ ttl: 60 // optional
11
+ });
12
+
13
+ console.log(result);
@@ -12,7 +12,8 @@ const result = await databases.decrementDocumentAttribute({
12
12
  documentId: '<DOCUMENT_ID>',
13
13
  attribute: '',
14
14
  value: 0, // optional
15
- min: 0 // optional
15
+ min: 0, // optional
16
+ transactionId: '<TRANSACTION_ID>' // optional
16
17
  });
17
18
 
18
19
  console.log(result);
@@ -9,7 +9,8 @@ const databases = new Databases(client);
9
9
  const result = await databases.deleteDocument({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  collectionId: '<COLLECTION_ID>',
12
- documentId: '<DOCUMENT_ID>'
12
+ documentId: '<DOCUMENT_ID>',
13
+ transactionId: '<TRANSACTION_ID>' // optional
13
14
  });
14
15
 
15
16
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.deleteTransaction({
10
+ transactionId: '<TRANSACTION_ID>'
11
+ });
12
+
13
+ console.log(result);
@@ -10,7 +10,8 @@ const result = await databases.getDocument({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  collectionId: '<COLLECTION_ID>',
12
12
  documentId: '<DOCUMENT_ID>',
13
- queries: [] // optional
13
+ queries: [], // optional
14
+ transactionId: '<TRANSACTION_ID>' // optional
14
15
  });
15
16
 
16
17
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.getTransaction({
10
+ transactionId: '<TRANSACTION_ID>'
11
+ });
12
+
13
+ console.log(result);
@@ -12,7 +12,8 @@ const result = await databases.incrementDocumentAttribute({
12
12
  documentId: '<DOCUMENT_ID>',
13
13
  attribute: '',
14
14
  value: 0, // optional
15
- max: 0 // optional
15
+ max: 0, // optional
16
+ transactionId: '<TRANSACTION_ID>' // optional
16
17
  });
17
18
 
18
19
  console.log(result);
@@ -9,7 +9,9 @@ const databases = new Databases(client);
9
9
  const result = await databases.listDocuments({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  collectionId: '<COLLECTION_ID>',
12
- queries: [] // optional
12
+ queries: [], // optional
13
+ transactionId: '<TRANSACTION_ID>', // optional
14
+ total: false // optional
13
15
  });
14
16
 
15
17
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.listTransactions({
10
+ queries: [] // optional
11
+ });
12
+
13
+ console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, Databases } from "react-native-appwrite";
1
+ import { Client, Databases, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -11,7 +11,8 @@ const result = await databases.updateDocument({
11
11
  collectionId: '<COLLECTION_ID>',
12
12
  documentId: '<DOCUMENT_ID>',
13
13
  data: {}, // optional
14
- permissions: ["read("any")"] // optional
14
+ permissions: ["read("any")"], // optional
15
+ transactionId: '<TRANSACTION_ID>' // optional
15
16
  });
16
17
 
17
18
  console.log(result);
@@ -0,0 +1,15 @@
1
+ import { Client, Databases } from "react-native-appwrite";
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
+
7
+ const databases = new Databases(client);
8
+
9
+ const result = await databases.updateTransaction({
10
+ transactionId: '<TRANSACTION_ID>',
11
+ commit: false, // optional
12
+ rollback: false // optional
13
+ });
14
+
15
+ console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, Databases } from "react-native-appwrite";
1
+ import { Client, Databases, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -11,7 +11,8 @@ const result = await databases.upsertDocument({
11
11
  collectionId: '<COLLECTION_ID>',
12
12
  documentId: '<DOCUMENT_ID>',
13
13
  data: {},
14
- permissions: ["read("any")"] // optional
14
+ permissions: ["read("any")"], // optional
15
+ transactionId: '<TRANSACTION_ID>' // optional
15
16
  });
16
17
 
17
18
  console.log(result);
@@ -8,7 +8,8 @@ const functions = new Functions(client);
8
8
 
9
9
  const result = await functions.listExecutions({
10
10
  functionId: '<FUNCTION_ID>',
11
- queries: [] // optional
11
+ queries: [], // optional
12
+ total: false // optional
12
13
  });
13
14
 
14
15
  console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, Storage } from "react-native-appwrite";
1
+ import { Client, Storage, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -9,7 +9,8 @@ const storage = new Storage(client);
9
9
  const result = await storage.listFiles({
10
10
  bucketId: '<BUCKET_ID>',
11
11
  queries: [], // optional
12
- search: '<SEARCH>' // optional
12
+ search: '<SEARCH>', // optional
13
+ total: false // optional
13
14
  });
14
15
 
15
16
  console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, Storage } from "react-native-appwrite";
1
+ import { Client, Storage, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -0,0 +1,24 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.createOperations({
10
+ transactionId: '<TRANSACTION_ID>',
11
+ operations: [
12
+ {
13
+ "action": "create",
14
+ "databaseId": "<DATABASE_ID>",
15
+ "tableId": "<TABLE_ID>",
16
+ "rowId": "<ROW_ID>",
17
+ "data": {
18
+ "name": "Walter O'Brien"
19
+ }
20
+ }
21
+ ] // optional
22
+ });
23
+
24
+ console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, TablesDB } from "react-native-appwrite";
1
+ import { Client, TablesDB, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -17,7 +17,8 @@ const result = await tablesDB.createRow({
17
17
  "age": 30,
18
18
  "isAdmin": false
19
19
  },
20
- permissions: ["read("any")"] // optional
20
+ permissions: ["read("any")"], // optional
21
+ transactionId: '<TRANSACTION_ID>' // optional
21
22
  });
22
23
 
23
24
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.createTransaction({
10
+ ttl: 60 // optional
11
+ });
12
+
13
+ console.log(result);
@@ -12,7 +12,8 @@ const result = await tablesDB.decrementRowColumn({
12
12
  rowId: '<ROW_ID>',
13
13
  column: '',
14
14
  value: 0, // optional
15
- min: 0 // optional
15
+ min: 0, // optional
16
+ transactionId: '<TRANSACTION_ID>' // optional
16
17
  });
17
18
 
18
19
  console.log(result);
@@ -9,7 +9,8 @@ const tablesDB = new TablesDB(client);
9
9
  const result = await tablesDB.deleteRow({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  tableId: '<TABLE_ID>',
12
- rowId: '<ROW_ID>'
12
+ rowId: '<ROW_ID>',
13
+ transactionId: '<TRANSACTION_ID>' // optional
13
14
  });
14
15
 
15
16
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.deleteTransaction({
10
+ transactionId: '<TRANSACTION_ID>'
11
+ });
12
+
13
+ console.log(result);
@@ -10,7 +10,8 @@ const result = await tablesDB.getRow({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  tableId: '<TABLE_ID>',
12
12
  rowId: '<ROW_ID>',
13
- queries: [] // optional
13
+ queries: [], // optional
14
+ transactionId: '<TRANSACTION_ID>' // optional
14
15
  });
15
16
 
16
17
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.getTransaction({
10
+ transactionId: '<TRANSACTION_ID>'
11
+ });
12
+
13
+ console.log(result);
@@ -12,7 +12,8 @@ const result = await tablesDB.incrementRowColumn({
12
12
  rowId: '<ROW_ID>',
13
13
  column: '',
14
14
  value: 0, // optional
15
- max: 0 // optional
15
+ max: 0, // optional
16
+ transactionId: '<TRANSACTION_ID>' // optional
16
17
  });
17
18
 
18
19
  console.log(result);
@@ -9,7 +9,9 @@ const tablesDB = new TablesDB(client);
9
9
  const result = await tablesDB.listRows({
10
10
  databaseId: '<DATABASE_ID>',
11
11
  tableId: '<TABLE_ID>',
12
- queries: [] // optional
12
+ queries: [], // optional
13
+ transactionId: '<TRANSACTION_ID>', // optional
14
+ total: false // optional
13
15
  });
14
16
 
15
17
  console.log(result);
@@ -0,0 +1,13 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.listTransactions({
10
+ queries: [] // optional
11
+ });
12
+
13
+ console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, TablesDB } from "react-native-appwrite";
1
+ import { Client, TablesDB, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -11,7 +11,8 @@ const result = await tablesDB.updateRow({
11
11
  tableId: '<TABLE_ID>',
12
12
  rowId: '<ROW_ID>',
13
13
  data: {}, // optional
14
- permissions: ["read("any")"] // optional
14
+ permissions: ["read("any")"], // optional
15
+ transactionId: '<TRANSACTION_ID>' // optional
15
16
  });
16
17
 
17
18
  console.log(result);
@@ -0,0 +1,15 @@
1
+ import { Client, TablesDB } from "react-native-appwrite";
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
+
7
+ const tablesDB = new TablesDB(client);
8
+
9
+ const result = await tablesDB.updateTransaction({
10
+ transactionId: '<TRANSACTION_ID>',
11
+ commit: false, // optional
12
+ rollback: false // optional
13
+ });
14
+
15
+ console.log(result);
@@ -1,4 +1,4 @@
1
- import { Client, TablesDB } from "react-native-appwrite";
1
+ import { Client, TablesDB, Permission, Role } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
@@ -11,7 +11,8 @@ const result = await tablesDB.upsertRow({
11
11
  tableId: '<TABLE_ID>',
12
12
  rowId: '<ROW_ID>',
13
13
  data: {}, // optional
14
- permissions: ["read("any")"] // optional
14
+ permissions: ["read("any")"], // optional
15
+ transactionId: '<TRANSACTION_ID>' // optional
15
16
  });
16
17
 
17
18
  console.log(result);
@@ -9,7 +9,8 @@ const teams = new Teams(client);
9
9
  const result = await teams.listMemberships({
10
10
  teamId: '<TEAM_ID>',
11
11
  queries: [], // optional
12
- search: '<SEARCH>' // optional
12
+ search: '<SEARCH>', // optional
13
+ total: false // optional
13
14
  });
14
15
 
15
16
  console.log(result);
@@ -8,7 +8,8 @@ const teams = new Teams(client);
8
8
 
9
9
  const result = await teams.list({
10
10
  queries: [], // optional
11
- search: '<SEARCH>' // optional
11
+ search: '<SEARCH>', // optional
12
+ total: false // optional
12
13
  });
13
14
 
14
15
  console.log(result);
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "react-native-appwrite",
3
3
  "homepage": "https://appwrite.io/support",
4
4
  "description": "Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API",
5
- "version": "0.16.0",
5
+ "version": "0.18.0",
6
6
  "license": "BSD-3-Clause",
7
7
  "main": "dist/cjs/sdk.js",
8
8
  "exports": {
@@ -37,7 +37,6 @@
37
37
  "react-native": ">=0.76.7 <1.0.0"
38
38
  },
39
39
  "peerDependencies": {
40
- "expo": "*",
41
- "react-native": "*"
40
+ "expo": "*"
42
41
  }
43
42
  }
package/src/client.ts CHANGED
@@ -115,7 +115,7 @@ class Client {
115
115
  'x-sdk-name': 'React Native',
116
116
  'x-sdk-platform': 'client',
117
117
  'x-sdk-language': 'reactnative',
118
- 'x-sdk-version': '0.16.0',
118
+ 'x-sdk-version': '0.18.0',
119
119
  'X-Appwrite-Response-Format': '1.8.0',
120
120
  };
121
121
 
@@ -3,4 +3,5 @@ export enum ExecutionStatus {
3
3
  Processing = 'processing',
4
4
  Completed = 'completed',
5
5
  Failed = 'failed',
6
+ Scheduled = 'scheduled',
6
7
  }
package/src/index.ts CHANGED
@@ -15,6 +15,7 @@ export { Query } from './query';
15
15
  export { Permission } from './permission';
16
16
  export { Role } from './role';
17
17
  export { ID } from './id';
18
+ export { Operator, Condition } from './operator';
18
19
  export { AuthenticatorType } from './enums/authenticator-type';
19
20
  export { AuthenticationFactor } from './enums/authentication-factor';
20
21
  export { OAuthProvider } from './enums/o-auth-provider';
@@ -24,3 +25,5 @@ export { Flag } from './enums/flag';
24
25
  export { ExecutionMethod } from './enums/execution-method';
25
26
  export { ImageGravity } from './enums/image-gravity';
26
27
  export { ImageFormat } from './enums/image-format';
28
+ export { ExecutionTrigger } from './enums/execution-trigger';
29
+ export { ExecutionStatus } from './enums/execution-status';
package/src/models.ts CHANGED
@@ -215,6 +215,20 @@ export namespace Models {
215
215
  localeCodes: LocaleCode[];
216
216
  }
217
217
 
218
+ /**
219
+ * Transaction List
220
+ */
221
+ export type TransactionList = {
222
+ /**
223
+ * Total number of transactions that matched your query.
224
+ */
225
+ total: number;
226
+ /**
227
+ * List of transactions.
228
+ */
229
+ transactions: Transaction[];
230
+ }
231
+
218
232
  /**
219
233
  * Row
220
234
  */
@@ -1013,7 +1027,7 @@ export namespace Models {
1013
1027
  */
1014
1028
  trigger: ExecutionTrigger;
1015
1029
  /**
1016
- * The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, or `failed`.
1030
+ * The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, `failed`, or `scheduled`.
1017
1031
  */
1018
1032
  status: ExecutionStatus;
1019
1033
  /**
@@ -1238,6 +1252,36 @@ export namespace Models {
1238
1252
  recoveryCode: boolean;
1239
1253
  }
1240
1254
 
1255
+ /**
1256
+ * Transaction
1257
+ */
1258
+ export type Transaction = {
1259
+ /**
1260
+ * Transaction ID.
1261
+ */
1262
+ $id: string;
1263
+ /**
1264
+ * Transaction creation time in ISO 8601 format.
1265
+ */
1266
+ $createdAt: string;
1267
+ /**
1268
+ * Transaction update date in ISO 8601 format.
1269
+ */
1270
+ $updatedAt: string;
1271
+ /**
1272
+ * Current status of the transaction. One of: pending, committing, committed, rolled_back, failed.
1273
+ */
1274
+ status: string;
1275
+ /**
1276
+ * Number of operations in the transaction.
1277
+ */
1278
+ operations: number;
1279
+ /**
1280
+ * Expiration time in ISO 8601 format.
1281
+ */
1282
+ expiresAt: string;
1283
+ }
1284
+
1241
1285
  /**
1242
1286
  * Subscriber
1243
1287
  */