@appwrite.io/console 0.1.1 → 0.3.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 (317) hide show
  1. package/.github/workflows/publish.yml +18 -0
  2. package/README.md +2 -2
  3. package/dist/cjs/sdk.js +2417 -630
  4. package/dist/cjs/sdk.js.map +1 -1
  5. package/dist/esm/sdk.js +2413 -631
  6. package/dist/esm/sdk.js.map +1 -1
  7. package/dist/iife/sdk.js +2417 -630
  8. package/docs/examples/account/create-anonymous-session.md +1 -1
  9. package/docs/examples/account/create-email-session.md +1 -1
  10. package/docs/examples/account/create-j-w-t.md +1 -1
  11. package/docs/examples/account/create-magic-u-r-l-session.md +1 -1
  12. package/docs/examples/account/create-o-auth2session.md +1 -1
  13. package/docs/examples/account/create-phone-session.md +1 -1
  14. package/docs/examples/account/create-phone-verification.md +1 -1
  15. package/docs/examples/account/create-recovery.md +1 -1
  16. package/docs/examples/account/create-verification.md +1 -1
  17. package/docs/examples/account/create-with-invite-code.md +18 -0
  18. package/docs/examples/account/create.md +1 -1
  19. package/docs/examples/account/delete-identity.md +18 -0
  20. package/docs/examples/account/delete-session.md +1 -1
  21. package/docs/examples/account/delete-sessions.md +1 -1
  22. package/docs/examples/account/get-prefs.md +1 -1
  23. package/docs/examples/account/get-session.md +1 -1
  24. package/docs/examples/account/get.md +1 -1
  25. package/docs/examples/account/list-identities.md +18 -0
  26. package/docs/examples/account/list-logs.md +1 -1
  27. package/docs/examples/account/list-sessions.md +1 -1
  28. package/docs/examples/account/update-email.md +1 -1
  29. package/docs/examples/account/update-magic-u-r-l-session.md +1 -1
  30. package/docs/examples/account/update-name.md +1 -1
  31. package/docs/examples/account/update-password.md +1 -1
  32. package/docs/examples/account/update-phone-session.md +1 -1
  33. package/docs/examples/account/update-phone-verification.md +1 -1
  34. package/docs/examples/account/update-phone.md +1 -1
  35. package/docs/examples/account/update-prefs.md +1 -1
  36. package/docs/examples/account/update-recovery.md +1 -1
  37. package/docs/examples/account/update-session.md +1 -1
  38. package/docs/examples/account/update-status.md +1 -1
  39. package/docs/examples/account/update-verification.md +1 -1
  40. package/docs/examples/assistant/chat.md +18 -0
  41. package/docs/examples/avatars/get-browser.md +1 -1
  42. package/docs/examples/avatars/get-credit-card.md +1 -1
  43. package/docs/examples/avatars/get-favicon.md +1 -1
  44. package/docs/examples/avatars/get-flag.md +1 -1
  45. package/docs/examples/avatars/get-image.md +1 -1
  46. package/docs/examples/avatars/get-initials.md +1 -1
  47. package/docs/examples/avatars/get-q-r.md +1 -1
  48. package/docs/examples/console/variables.md +1 -1
  49. package/docs/examples/databases/create-boolean-attribute.md +1 -1
  50. package/docs/examples/databases/create-collection.md +1 -1
  51. package/docs/examples/databases/create-datetime-attribute.md +1 -1
  52. package/docs/examples/databases/create-document.md +1 -1
  53. package/docs/examples/databases/create-email-attribute.md +1 -1
  54. package/docs/examples/databases/create-enum-attribute.md +1 -1
  55. package/docs/examples/databases/create-float-attribute.md +1 -1
  56. package/docs/examples/databases/create-index.md +1 -1
  57. package/docs/examples/databases/create-integer-attribute.md +1 -1
  58. package/docs/examples/databases/create-ip-attribute.md +1 -1
  59. package/docs/examples/databases/create-relationship-attribute.md +1 -1
  60. package/docs/examples/databases/create-string-attribute.md +1 -1
  61. package/docs/examples/databases/create-url-attribute.md +1 -1
  62. package/docs/examples/databases/create.md +1 -1
  63. package/docs/examples/databases/delete-attribute.md +1 -1
  64. package/docs/examples/databases/delete-collection.md +1 -1
  65. package/docs/examples/databases/delete-document.md +1 -1
  66. package/docs/examples/databases/delete-index.md +1 -1
  67. package/docs/examples/databases/delete.md +1 -1
  68. package/docs/examples/databases/get-attribute.md +1 -1
  69. package/docs/examples/databases/get-collection-usage.md +1 -1
  70. package/docs/examples/databases/get-collection.md +1 -1
  71. package/docs/examples/databases/get-database-usage.md +1 -1
  72. package/docs/examples/databases/get-document.md +1 -1
  73. package/docs/examples/databases/get-index.md +1 -1
  74. package/docs/examples/databases/get-usage.md +1 -1
  75. package/docs/examples/databases/get.md +1 -1
  76. package/docs/examples/databases/list-attributes.md +1 -1
  77. package/docs/examples/databases/list-collection-logs.md +1 -1
  78. package/docs/examples/databases/list-collections.md +1 -1
  79. package/docs/examples/databases/list-document-logs.md +1 -1
  80. package/docs/examples/databases/list-documents.md +1 -1
  81. package/docs/examples/databases/list-indexes.md +1 -1
  82. package/docs/examples/databases/list-logs.md +1 -1
  83. package/docs/examples/databases/list.md +1 -1
  84. package/docs/examples/databases/update-boolean-attribute.md +1 -1
  85. package/docs/examples/databases/update-collection.md +1 -1
  86. package/docs/examples/databases/update-datetime-attribute.md +1 -1
  87. package/docs/examples/databases/update-document.md +1 -1
  88. package/docs/examples/databases/update-email-attribute.md +1 -1
  89. package/docs/examples/databases/update-enum-attribute.md +1 -1
  90. package/docs/examples/databases/update-float-attribute.md +1 -1
  91. package/docs/examples/databases/update-integer-attribute.md +1 -1
  92. package/docs/examples/databases/update-ip-attribute.md +1 -1
  93. package/docs/examples/databases/update-relationship-attribute.md +1 -1
  94. package/docs/examples/databases/update-string-attribute.md +1 -1
  95. package/docs/examples/databases/update-url-attribute.md +1 -1
  96. package/docs/examples/databases/update.md +1 -1
  97. package/docs/examples/functions/create-build.md +1 -1
  98. package/docs/examples/functions/create-deployment.md +2 -2
  99. package/docs/examples/functions/create-execution.md +1 -1
  100. package/docs/examples/functions/create-variable.md +1 -1
  101. package/docs/examples/functions/create.md +1 -1
  102. package/docs/examples/functions/delete-deployment.md +1 -1
  103. package/docs/examples/functions/delete-variable.md +1 -1
  104. package/docs/examples/functions/delete.md +1 -1
  105. package/docs/examples/functions/download-deployment.md +14 -0
  106. package/docs/examples/functions/get-deployment.md +1 -1
  107. package/docs/examples/functions/get-execution.md +1 -1
  108. package/docs/examples/functions/get-function-usage.md +1 -1
  109. package/docs/examples/functions/get-usage.md +1 -1
  110. package/docs/examples/functions/get-variable.md +1 -1
  111. package/docs/examples/functions/get.md +1 -1
  112. package/docs/examples/functions/list-deployments.md +1 -1
  113. package/docs/examples/functions/list-executions.md +1 -1
  114. package/docs/examples/functions/list-runtimes.md +1 -1
  115. package/docs/examples/functions/list-variables.md +1 -1
  116. package/docs/examples/functions/list.md +1 -1
  117. package/docs/examples/functions/update-deployment.md +1 -1
  118. package/docs/examples/functions/update-variable.md +1 -1
  119. package/docs/examples/functions/update.md +2 -2
  120. package/docs/examples/graphql/mutation.md +1 -1
  121. package/docs/examples/graphql/query.md +1 -1
  122. package/docs/examples/health/get-antivirus.md +1 -1
  123. package/docs/examples/health/get-cache.md +1 -1
  124. package/docs/examples/health/get-d-b.md +1 -1
  125. package/docs/examples/health/get-pub-sub.md +18 -0
  126. package/docs/examples/health/get-queue-certificates.md +1 -1
  127. package/docs/examples/health/get-queue-functions.md +1 -1
  128. package/docs/examples/health/get-queue-logs.md +1 -1
  129. package/docs/examples/health/get-queue-webhooks.md +1 -1
  130. package/docs/examples/health/get-queue.md +18 -0
  131. package/docs/examples/health/get-storage-local.md +1 -1
  132. package/docs/examples/health/get-time.md +1 -1
  133. package/docs/examples/health/get.md +1 -1
  134. package/docs/examples/locale/get.md +1 -1
  135. package/docs/examples/locale/list-codes.md +18 -0
  136. package/docs/examples/locale/list-continents.md +1 -1
  137. package/docs/examples/locale/list-countries-e-u.md +1 -1
  138. package/docs/examples/locale/list-countries-phones.md +1 -1
  139. package/docs/examples/locale/list-countries.md +1 -1
  140. package/docs/examples/locale/list-currencies.md +1 -1
  141. package/docs/examples/locale/list-languages.md +1 -1
  142. package/docs/examples/migrations/create-appwrite-migration.md +18 -0
  143. package/docs/examples/migrations/create-firebase-migration.md +18 -0
  144. package/docs/examples/migrations/create-firebase-o-auth-migration.md +18 -0
  145. package/docs/examples/migrations/create-n-host-migration.md +18 -0
  146. package/docs/examples/migrations/create-supabase-migration.md +18 -0
  147. package/docs/examples/migrations/delete-firebase-auth.md +18 -0
  148. package/docs/examples/migrations/delete.md +18 -0
  149. package/docs/examples/migrations/get-appwrite-report.md +18 -0
  150. package/docs/examples/migrations/get-firebase-report-o-auth.md +18 -0
  151. package/docs/examples/migrations/get-firebase-report.md +18 -0
  152. package/docs/examples/migrations/get-n-host-report.md +18 -0
  153. package/docs/examples/migrations/get-supabase-report.md +18 -0
  154. package/docs/examples/migrations/get.md +18 -0
  155. package/docs/examples/migrations/list-firebase-projects.md +18 -0
  156. package/docs/examples/migrations/list.md +18 -0
  157. package/docs/examples/migrations/retry.md +18 -0
  158. package/docs/examples/project/create-variable.md +18 -0
  159. package/docs/examples/project/delete-variable.md +18 -0
  160. package/docs/examples/project/get-usage.md +18 -0
  161. package/docs/examples/project/get-variable.md +18 -0
  162. package/docs/examples/project/list-variables.md +18 -0
  163. package/docs/examples/project/update-variable.md +18 -0
  164. package/docs/examples/projects/create-key.md +1 -1
  165. package/docs/examples/projects/create-platform.md +1 -1
  166. package/docs/examples/projects/create-webhook.md +1 -1
  167. package/docs/examples/projects/create.md +2 -2
  168. package/docs/examples/projects/delete-email-template.md +18 -0
  169. package/docs/examples/projects/delete-key.md +1 -1
  170. package/docs/examples/projects/delete-platform.md +1 -1
  171. package/docs/examples/projects/delete-sms-template.md +18 -0
  172. package/docs/examples/projects/delete-webhook.md +1 -1
  173. package/docs/examples/projects/delete.md +2 -2
  174. package/docs/examples/projects/get-email-template.md +18 -0
  175. package/docs/examples/projects/get-key.md +1 -1
  176. package/docs/examples/projects/get-platform.md +1 -1
  177. package/docs/examples/projects/get-sms-template.md +18 -0
  178. package/docs/examples/projects/get-usage.md +1 -1
  179. package/docs/examples/projects/get-webhook.md +1 -1
  180. package/docs/examples/projects/get.md +1 -1
  181. package/docs/examples/projects/list-keys.md +1 -1
  182. package/docs/examples/projects/list-platforms.md +1 -1
  183. package/docs/examples/projects/list-webhooks.md +1 -1
  184. package/docs/examples/projects/list.md +1 -1
  185. package/docs/examples/projects/update-auth-duration.md +1 -1
  186. package/docs/examples/projects/update-auth-limit.md +1 -1
  187. package/docs/examples/projects/update-auth-password-dictionary.md +1 -1
  188. package/docs/examples/projects/update-auth-password-history.md +1 -1
  189. package/docs/examples/projects/update-auth-sessions-limit.md +1 -1
  190. package/docs/examples/projects/update-auth-status.md +1 -1
  191. package/docs/examples/projects/update-email-template.md +18 -0
  192. package/docs/examples/projects/update-key.md +1 -1
  193. package/docs/examples/projects/update-o-auth2.md +1 -1
  194. package/docs/examples/projects/{delete-domain.md → update-personal-data-check.md} +2 -2
  195. package/docs/examples/projects/update-platform.md +1 -1
  196. package/docs/examples/projects/{create-domain.md → update-service-status-all.md} +2 -2
  197. package/docs/examples/projects/update-service-status.md +1 -1
  198. package/docs/examples/projects/update-sms-template.md +18 -0
  199. package/docs/examples/projects/{get-domain.md → update-smtp-configuration.md} +2 -2
  200. package/docs/examples/projects/{list-domains.md → update-team.md} +2 -2
  201. package/docs/examples/projects/update-webhook-signature.md +1 -1
  202. package/docs/examples/projects/update-webhook.md +1 -1
  203. package/docs/examples/projects/update.md +1 -1
  204. package/docs/examples/proxy/create-rule.md +18 -0
  205. package/docs/examples/proxy/delete-rule.md +18 -0
  206. package/docs/examples/proxy/get-rule.md +18 -0
  207. package/docs/examples/proxy/list-rules.md +18 -0
  208. package/docs/examples/proxy/update-rule-verification.md +18 -0
  209. package/docs/examples/storage/create-bucket.md +1 -1
  210. package/docs/examples/storage/create-file.md +1 -1
  211. package/docs/examples/storage/delete-bucket.md +1 -1
  212. package/docs/examples/storage/delete-file.md +1 -1
  213. package/docs/examples/storage/get-bucket-usage.md +1 -1
  214. package/docs/examples/storage/get-bucket.md +1 -1
  215. package/docs/examples/storage/get-file-download.md +1 -1
  216. package/docs/examples/storage/get-file-preview.md +1 -1
  217. package/docs/examples/storage/get-file-view.md +1 -1
  218. package/docs/examples/storage/get-file.md +1 -1
  219. package/docs/examples/storage/get-usage.md +1 -1
  220. package/docs/examples/storage/list-buckets.md +1 -1
  221. package/docs/examples/storage/list-files.md +1 -1
  222. package/docs/examples/storage/update-bucket.md +1 -1
  223. package/docs/examples/storage/update-file.md +1 -1
  224. package/docs/examples/teams/create-membership.md +1 -1
  225. package/docs/examples/teams/create.md +1 -1
  226. package/docs/examples/teams/delete-membership.md +1 -1
  227. package/docs/examples/teams/delete.md +1 -1
  228. package/docs/examples/teams/get-membership.md +1 -1
  229. package/docs/examples/teams/get-prefs.md +1 -1
  230. package/docs/examples/teams/get.md +1 -1
  231. package/docs/examples/teams/list-logs.md +1 -1
  232. package/docs/examples/teams/list-memberships.md +1 -1
  233. package/docs/examples/teams/list.md +1 -1
  234. package/docs/examples/teams/update-membership-status.md +1 -1
  235. package/docs/examples/teams/{update-membership-roles.md → update-membership.md} +2 -2
  236. package/docs/examples/teams/update-name.md +1 -1
  237. package/docs/examples/teams/update-prefs.md +1 -1
  238. package/docs/examples/users/create-argon2user.md +1 -1
  239. package/docs/examples/users/create-bcrypt-user.md +1 -1
  240. package/docs/examples/users/create-m-d5user.md +1 -1
  241. package/docs/examples/users/create-p-h-pass-user.md +1 -1
  242. package/docs/examples/users/create-s-h-a-user.md +1 -1
  243. package/docs/examples/users/create-scrypt-modified-user.md +1 -1
  244. package/docs/examples/users/create-scrypt-user.md +1 -1
  245. package/docs/examples/users/create.md +1 -1
  246. package/docs/examples/users/delete-identity.md +18 -0
  247. package/docs/examples/users/delete-session.md +1 -1
  248. package/docs/examples/users/delete-sessions.md +1 -1
  249. package/docs/examples/users/delete.md +1 -1
  250. package/docs/examples/users/get-prefs.md +1 -1
  251. package/docs/examples/users/get-usage.md +1 -1
  252. package/docs/examples/users/get.md +1 -1
  253. package/docs/examples/users/list-identities.md +18 -0
  254. package/docs/examples/users/list-logs.md +1 -1
  255. package/docs/examples/users/list-memberships.md +1 -1
  256. package/docs/examples/users/list-sessions.md +1 -1
  257. package/docs/examples/users/list.md +1 -1
  258. package/docs/examples/users/update-email-verification.md +1 -1
  259. package/docs/examples/users/update-email.md +1 -1
  260. package/docs/examples/users/update-labels.md +18 -0
  261. package/docs/examples/users/update-name.md +1 -1
  262. package/docs/examples/users/update-password.md +1 -1
  263. package/docs/examples/users/update-phone-verification.md +1 -1
  264. package/docs/examples/users/update-phone.md +1 -1
  265. package/docs/examples/users/update-prefs.md +1 -1
  266. package/docs/examples/users/update-status.md +1 -1
  267. package/docs/examples/vcs/create-repository-detection.md +18 -0
  268. package/docs/examples/vcs/create-repository.md +18 -0
  269. package/docs/examples/vcs/delete-installation.md +18 -0
  270. package/docs/examples/vcs/get-installation.md +18 -0
  271. package/docs/examples/vcs/get-repository.md +18 -0
  272. package/docs/examples/vcs/list-installations.md +18 -0
  273. package/docs/examples/vcs/list-repositories.md +18 -0
  274. package/docs/examples/vcs/list-repository-branches.md +18 -0
  275. package/docs/examples/vcs/update-external-deployments.md +18 -0
  276. package/package.json +1 -1
  277. package/src/client.ts +2 -2
  278. package/src/index.ts +5 -0
  279. package/src/models.ts +750 -78
  280. package/src/services/account.ts +1102 -995
  281. package/src/services/assistant.ts +38 -0
  282. package/src/services/avatars.ts +337 -337
  283. package/src/services/console.ts +16 -16
  284. package/src/services/databases.ts +2170 -2140
  285. package/src/services/functions.ts +808 -652
  286. package/src/services/graphql.ts +47 -47
  287. package/src/services/health.ts +226 -189
  288. package/src/services/locale.ts +156 -137
  289. package/src/services/migrations.ts +707 -0
  290. package/src/services/project.ts +174 -0
  291. package/src/services/projects.ts +1538 -1283
  292. package/src/services/proxy.ts +150 -0
  293. package/src/services/storage.ts +576 -571
  294. package/src/services/teams.ts +502 -501
  295. package/src/services/users.ts +1094 -1006
  296. package/src/services/vcs.ts +272 -0
  297. package/types/index.d.ts +5 -0
  298. package/types/models.d.ts +750 -78
  299. package/types/services/account.d.ts +80 -40
  300. package/types/services/assistant.d.ts +14 -0
  301. package/types/services/avatars.d.ts +7 -7
  302. package/types/services/console.d.ts +1 -1
  303. package/types/services/databases.d.ts +60 -54
  304. package/types/services/functions.d.ts +66 -31
  305. package/types/services/graphql.d.ts +2 -2
  306. package/types/services/health.d.ts +31 -12
  307. package/types/services/locale.d.ts +17 -7
  308. package/types/services/migrations.d.ts +185 -0
  309. package/types/services/project.d.ts +70 -0
  310. package/types/services/projects.d.ts +150 -80
  311. package/types/services/proxy.d.ts +59 -0
  312. package/types/services/storage.d.ts +17 -16
  313. package/types/services/teams.d.ts +17 -16
  314. package/types/services/users.d.ts +63 -26
  315. package/types/services/vcs.d.ts +97 -0
  316. package/.travis.yml +0 -32
  317. package/docs/examples/projects/update-domain-verification.md +0 -18
@@ -14,7 +14,7 @@ export declare class Storage extends Service {
14
14
  * @param {string} search
15
15
  * @throws {AppwriteException}
16
16
  * @returns {Promise}
17
- */
17
+ */
18
18
  listBuckets(queries?: string[], search?: string): Promise<Models.BucketList>;
19
19
  /**
20
20
  * Create bucket
@@ -33,7 +33,7 @@ export declare class Storage extends Service {
33
33
  * @param {boolean} antivirus
34
34
  * @throws {AppwriteException}
35
35
  * @returns {Promise}
36
- */
36
+ */
37
37
  createBucket(bucketId: string, name: string, permissions?: string[], fileSecurity?: boolean, enabled?: boolean, maximumFileSize?: number, allowedFileExtensions?: string[], compression?: string, encryption?: boolean, antivirus?: boolean): Promise<Models.Bucket>;
38
38
  /**
39
39
  * Get Bucket
@@ -44,7 +44,7 @@ export declare class Storage extends Service {
44
44
  * @param {string} bucketId
45
45
  * @throws {AppwriteException}
46
46
  * @returns {Promise}
47
- */
47
+ */
48
48
  getBucket(bucketId: string): Promise<Models.Bucket>;
49
49
  /**
50
50
  * Update Bucket
@@ -63,7 +63,7 @@ export declare class Storage extends Service {
63
63
  * @param {boolean} antivirus
64
64
  * @throws {AppwriteException}
65
65
  * @returns {Promise}
66
- */
66
+ */
67
67
  updateBucket(bucketId: string, name: string, permissions?: string[], fileSecurity?: boolean, enabled?: boolean, maximumFileSize?: number, allowedFileExtensions?: string[], compression?: string, encryption?: boolean, antivirus?: boolean): Promise<Models.Bucket>;
68
68
  /**
69
69
  * Delete Bucket
@@ -73,7 +73,7 @@ export declare class Storage extends Service {
73
73
  * @param {string} bucketId
74
74
  * @throws {AppwriteException}
75
75
  * @returns {Promise}
76
- */
76
+ */
77
77
  deleteBucket(bucketId: string): Promise<{}>;
78
78
  /**
79
79
  * List Files
@@ -86,7 +86,7 @@ export declare class Storage extends Service {
86
86
  * @param {string} search
87
87
  * @throws {AppwriteException}
88
88
  * @returns {Promise}
89
- */
89
+ */
90
90
  listFiles(bucketId: string, queries?: string[], search?: string): Promise<Models.FileList>;
91
91
  /**
92
92
  * Create File
@@ -116,7 +116,7 @@ export declare class Storage extends Service {
116
116
  * @param {string[]} permissions
117
117
  * @throws {AppwriteException}
118
118
  * @returns {Promise}
119
- */
119
+ */
120
120
  createFile(bucketId: string, fileId: string, file: File, permissions?: string[], onProgress?: (progress: UploadProgress) => void): Promise<Models.File>;
121
121
  /**
122
122
  * Get File
@@ -128,7 +128,7 @@ export declare class Storage extends Service {
128
128
  * @param {string} fileId
129
129
  * @throws {AppwriteException}
130
130
  * @returns {Promise}
131
- */
131
+ */
132
132
  getFile(bucketId: string, fileId: string): Promise<Models.File>;
133
133
  /**
134
134
  * Update File
@@ -138,11 +138,12 @@ export declare class Storage extends Service {
138
138
  *
139
139
  * @param {string} bucketId
140
140
  * @param {string} fileId
141
+ * @param {string} name
141
142
  * @param {string[]} permissions
142
143
  * @throws {AppwriteException}
143
144
  * @returns {Promise}
144
- */
145
- updateFile(bucketId: string, fileId: string, permissions?: string[]): Promise<Models.File>;
145
+ */
146
+ updateFile(bucketId: string, fileId: string, name?: string, permissions?: string[]): Promise<Models.File>;
146
147
  /**
147
148
  * Delete File
148
149
  *
@@ -153,7 +154,7 @@ export declare class Storage extends Service {
153
154
  * @param {string} fileId
154
155
  * @throws {AppwriteException}
155
156
  * @returns {Promise}
156
- */
157
+ */
157
158
  deleteFile(bucketId: string, fileId: string): Promise<{}>;
158
159
  /**
159
160
  * Get File for Download
@@ -166,7 +167,7 @@ export declare class Storage extends Service {
166
167
  * @param {string} fileId
167
168
  * @throws {AppwriteException}
168
169
  * @returns {URL}
169
- */
170
+ */
170
171
  getFileDownload(bucketId: string, fileId: string): URL;
171
172
  /**
172
173
  * Get File Preview
@@ -192,7 +193,7 @@ export declare class Storage extends Service {
192
193
  * @param {string} output
193
194
  * @throws {AppwriteException}
194
195
  * @returns {URL}
195
- */
196
+ */
196
197
  getFilePreview(bucketId: string, fileId: string, width?: number, height?: number, gravity?: string, quality?: number, borderWidth?: number, borderColor?: string, borderRadius?: number, opacity?: number, rotation?: number, background?: string, output?: string): URL;
197
198
  /**
198
199
  * Get File for View
@@ -205,7 +206,7 @@ export declare class Storage extends Service {
205
206
  * @param {string} fileId
206
207
  * @throws {AppwriteException}
207
208
  * @returns {URL}
208
- */
209
+ */
209
210
  getFileView(bucketId: string, fileId: string): URL;
210
211
  /**
211
212
  * Get usage stats for storage
@@ -214,7 +215,7 @@ export declare class Storage extends Service {
214
215
  * @param {string} range
215
216
  * @throws {AppwriteException}
216
217
  * @returns {Promise}
217
- */
218
+ */
218
219
  getUsage(range?: string): Promise<Models.UsageStorage>;
219
220
  /**
220
221
  * Get usage stats for a storage bucket
@@ -224,6 +225,6 @@ export declare class Storage extends Service {
224
225
  * @param {string} range
225
226
  * @throws {AppwriteException}
226
227
  * @returns {Promise}
227
- */
228
+ */
228
229
  getBucketUsage(bucketId: string, range?: string): Promise<Models.UsageBuckets>;
229
230
  }
@@ -13,7 +13,7 @@ export declare class Teams extends Service {
13
13
  * @param {string} search
14
14
  * @throws {AppwriteException}
15
15
  * @returns {Promise}
16
- */
16
+ */
17
17
  list<Preferences extends Models.Preferences>(queries?: string[], search?: string): Promise<Models.TeamList<Preferences>>;
18
18
  /**
19
19
  * Create Team
@@ -27,7 +27,7 @@ export declare class Teams extends Service {
27
27
  * @param {string[]} roles
28
28
  * @throws {AppwriteException}
29
29
  * @returns {Promise}
30
- */
30
+ */
31
31
  create<Preferences extends Models.Preferences>(teamId: string, name: string, roles?: string[]): Promise<Models.Team<Preferences>>;
32
32
  /**
33
33
  * Get Team
@@ -37,7 +37,7 @@ export declare class Teams extends Service {
37
37
  * @param {string} teamId
38
38
  * @throws {AppwriteException}
39
39
  * @returns {Promise}
40
- */
40
+ */
41
41
  get<Preferences extends Models.Preferences>(teamId: string): Promise<Models.Team<Preferences>>;
42
42
  /**
43
43
  * Update Name
@@ -48,7 +48,7 @@ export declare class Teams extends Service {
48
48
  * @param {string} name
49
49
  * @throws {AppwriteException}
50
50
  * @returns {Promise}
51
- */
51
+ */
52
52
  updateName<Preferences extends Models.Preferences>(teamId: string, name: string): Promise<Models.Team<Preferences>>;
53
53
  /**
54
54
  * Delete Team
@@ -59,7 +59,7 @@ export declare class Teams extends Service {
59
59
  * @param {string} teamId
60
60
  * @throws {AppwriteException}
61
61
  * @returns {Promise}
62
- */
62
+ */
63
63
  delete(teamId: string): Promise<{}>;
64
64
  /**
65
65
  * List Team Logs
@@ -70,7 +70,7 @@ export declare class Teams extends Service {
70
70
  * @param {string[]} queries
71
71
  * @throws {AppwriteException}
72
72
  * @returns {Promise}
73
- */
73
+ */
74
74
  listLogs(teamId: string, queries?: string[]): Promise<Models.LogList>;
75
75
  /**
76
76
  * List Team Memberships
@@ -83,7 +83,7 @@ export declare class Teams extends Service {
83
83
  * @param {string} search
84
84
  * @throws {AppwriteException}
85
85
  * @returns {Promise}
86
- */
86
+ */
87
87
  listMemberships(teamId: string, queries?: string[], search?: string): Promise<Models.MembershipList>;
88
88
  /**
89
89
  * Create Team Membership
@@ -119,7 +119,7 @@ export declare class Teams extends Service {
119
119
  * @param {string} name
120
120
  * @throws {AppwriteException}
121
121
  * @returns {Promise}
122
- */
122
+ */
123
123
  createMembership(teamId: string, roles: string[], url: string, email?: string, userId?: string, phone?: string, name?: string): Promise<Models.Membership>;
124
124
  /**
125
125
  * Get Team Membership
@@ -131,22 +131,23 @@ export declare class Teams extends Service {
131
131
  * @param {string} membershipId
132
132
  * @throws {AppwriteException}
133
133
  * @returns {Promise}
134
- */
134
+ */
135
135
  getMembership(teamId: string, membershipId: string): Promise<Models.Membership>;
136
136
  /**
137
- * Update Membership Roles
137
+ * Update Membership
138
138
  *
139
139
  * Modify the roles of a team member. Only team members with the owner role
140
140
  * have access to this endpoint. Learn more about [roles and
141
141
  * permissions](/docs/permissions).
142
142
  *
143
+ *
143
144
  * @param {string} teamId
144
145
  * @param {string} membershipId
145
146
  * @param {string[]} roles
146
147
  * @throws {AppwriteException}
147
148
  * @returns {Promise}
148
- */
149
- updateMembershipRoles(teamId: string, membershipId: string, roles: string[]): Promise<Models.Membership>;
149
+ */
150
+ updateMembership(teamId: string, membershipId: string, roles: string[]): Promise<Models.Membership>;
150
151
  /**
151
152
  * Delete Team Membership
152
153
  *
@@ -158,7 +159,7 @@ export declare class Teams extends Service {
158
159
  * @param {string} membershipId
159
160
  * @throws {AppwriteException}
160
161
  * @returns {Promise}
161
- */
162
+ */
162
163
  deleteMembership(teamId: string, membershipId: string): Promise<{}>;
163
164
  /**
164
165
  * Update Team Membership Status
@@ -177,7 +178,7 @@ export declare class Teams extends Service {
177
178
  * @param {string} secret
178
179
  * @throws {AppwriteException}
179
180
  * @returns {Promise}
180
- */
181
+ */
181
182
  updateMembershipStatus(teamId: string, membershipId: string, userId: string, secret: string): Promise<Models.Membership>;
182
183
  /**
183
184
  * Get Team Preferences
@@ -189,7 +190,7 @@ export declare class Teams extends Service {
189
190
  * @param {string} teamId
190
191
  * @throws {AppwriteException}
191
192
  * @returns {Promise}
192
- */
193
+ */
193
194
  getPrefs<Preferences extends Models.Preferences>(teamId: string): Promise<Preferences>;
194
195
  /**
195
196
  * Update Preferences
@@ -202,6 +203,6 @@ export declare class Teams extends Service {
202
203
  * @param {object} prefs
203
204
  * @throws {AppwriteException}
204
205
  * @returns {Promise}
205
- */
206
+ */
206
207
  updatePrefs<Preferences extends Models.Preferences>(teamId: string, prefs: object): Promise<Preferences>;
207
208
  }
@@ -13,7 +13,7 @@ export declare class Users extends Service {
13
13
  * @param {string} search
14
14
  * @throws {AppwriteException}
15
15
  * @returns {Promise}
16
- */
16
+ */
17
17
  list<Preferences extends Models.Preferences>(queries?: string[], search?: string): Promise<Models.UserList<Preferences>>;
18
18
  /**
19
19
  * Create User
@@ -27,7 +27,7 @@ export declare class Users extends Service {
27
27
  * @param {string} name
28
28
  * @throws {AppwriteException}
29
29
  * @returns {Promise}
30
- */
30
+ */
31
31
  create<Preferences extends Models.Preferences>(userId: string, email?: string, phone?: string, password?: string, name?: string): Promise<Models.User<Preferences>>;
32
32
  /**
33
33
  * Create User with Argon2 Password
@@ -43,7 +43,7 @@ export declare class Users extends Service {
43
43
  * @param {string} name
44
44
  * @throws {AppwriteException}
45
45
  * @returns {Promise}
46
- */
46
+ */
47
47
  createArgon2User<Preferences extends Models.Preferences>(userId: string, email: string, password: string, name?: string): Promise<Models.User<Preferences>>;
48
48
  /**
49
49
  * Create User with Bcrypt Password
@@ -59,8 +59,29 @@ export declare class Users extends Service {
59
59
  * @param {string} name
60
60
  * @throws {AppwriteException}
61
61
  * @returns {Promise}
62
- */
62
+ */
63
63
  createBcryptUser<Preferences extends Models.Preferences>(userId: string, email: string, password: string, name?: string): Promise<Models.User<Preferences>>;
64
+ /**
65
+ * List Identities
66
+ *
67
+ * Get identities for all users.
68
+ *
69
+ * @param {string} queries
70
+ * @param {string} search
71
+ * @throws {AppwriteException}
72
+ * @returns {Promise}
73
+ */
74
+ listIdentities(queries?: string, search?: string): Promise<Models.IdentityList>;
75
+ /**
76
+ * Delete Identity
77
+ *
78
+ * Delete an identity by its unique ID.
79
+ *
80
+ * @param {string} identityId
81
+ * @throws {AppwriteException}
82
+ * @returns {Promise}
83
+ */
84
+ deleteIdentity(identityId: string): Promise<{}>;
64
85
  /**
65
86
  * Create User with MD5 Password
66
87
  *
@@ -75,7 +96,7 @@ export declare class Users extends Service {
75
96
  * @param {string} name
76
97
  * @throws {AppwriteException}
77
98
  * @returns {Promise}
78
- */
99
+ */
79
100
  createMD5User<Preferences extends Models.Preferences>(userId: string, email: string, password: string, name?: string): Promise<Models.User<Preferences>>;
80
101
  /**
81
102
  * Create User with PHPass Password
@@ -91,7 +112,7 @@ export declare class Users extends Service {
91
112
  * @param {string} name
92
113
  * @throws {AppwriteException}
93
114
  * @returns {Promise}
94
- */
115
+ */
95
116
  createPHPassUser<Preferences extends Models.Preferences>(userId: string, email: string, password: string, name?: string): Promise<Models.User<Preferences>>;
96
117
  /**
97
118
  * Create User with Scrypt Password
@@ -112,7 +133,7 @@ export declare class Users extends Service {
112
133
  * @param {string} name
113
134
  * @throws {AppwriteException}
114
135
  * @returns {Promise}
115
- */
136
+ */
116
137
  createScryptUser<Preferences extends Models.Preferences>(userId: string, email: string, password: string, passwordSalt: string, passwordCpu: number, passwordMemory: number, passwordParallel: number, passwordLength: number, name?: string): Promise<Models.User<Preferences>>;
117
138
  /**
118
139
  * Create User with Scrypt Modified Password
@@ -131,7 +152,7 @@ export declare class Users extends Service {
131
152
  * @param {string} name
132
153
  * @throws {AppwriteException}
133
154
  * @returns {Promise}
134
- */
155
+ */
135
156
  createScryptModifiedUser<Preferences extends Models.Preferences>(userId: string, email: string, password: string, passwordSalt: string, passwordSaltSeparator: string, passwordSignerKey: string, name?: string): Promise<Models.User<Preferences>>;
136
157
  /**
137
158
  * Create User with SHA Password
@@ -148,7 +169,7 @@ export declare class Users extends Service {
148
169
  * @param {string} name
149
170
  * @throws {AppwriteException}
150
171
  * @returns {Promise}
151
- */
172
+ */
152
173
  createSHAUser<Preferences extends Models.Preferences>(userId: string, email: string, password: string, passwordVersion?: string, name?: string): Promise<Models.User<Preferences>>;
153
174
  /**
154
175
  * Get usage stats for the users API
@@ -158,7 +179,7 @@ export declare class Users extends Service {
158
179
  * @param {string} provider
159
180
  * @throws {AppwriteException}
160
181
  * @returns {Promise}
161
- */
182
+ */
162
183
  getUsage(range?: string, provider?: string): Promise<Models.UsageUsers>;
163
184
  /**
164
185
  * Get User
@@ -168,7 +189,7 @@ export declare class Users extends Service {
168
189
  * @param {string} userId
169
190
  * @throws {AppwriteException}
170
191
  * @returns {Promise}
171
- */
192
+ */
172
193
  get<Preferences extends Models.Preferences>(userId: string): Promise<Models.User<Preferences>>;
173
194
  /**
174
195
  * Delete User
@@ -182,7 +203,7 @@ export declare class Users extends Service {
182
203
  * @param {string} userId
183
204
  * @throws {AppwriteException}
184
205
  * @returns {Promise}
185
- */
206
+ */
186
207
  delete(userId: string): Promise<{}>;
187
208
  /**
188
209
  * Update Email
@@ -193,8 +214,24 @@ export declare class Users extends Service {
193
214
  * @param {string} email
194
215
  * @throws {AppwriteException}
195
216
  * @returns {Promise}
196
- */
217
+ */
197
218
  updateEmail<Preferences extends Models.Preferences>(userId: string, email: string): Promise<Models.User<Preferences>>;
219
+ /**
220
+ * Update User Labels
221
+ *
222
+ * Update the user labels by its unique ID.
223
+ *
224
+ * Labels can be used to grant access to resources. While teams are a way for
225
+ * user's to share access to a resource, labels can be defined by the
226
+ * developer to grant access without an invitation. See the [Permissions
227
+ * docs](/docs/permissions) for more info.
228
+ *
229
+ * @param {string} userId
230
+ * @param {string[]} labels
231
+ * @throws {AppwriteException}
232
+ * @returns {Promise}
233
+ */
234
+ updateLabels<Preferences extends Models.Preferences>(userId: string, labels: string[]): Promise<Models.User<Preferences>>;
198
235
  /**
199
236
  * List User Logs
200
237
  *
@@ -204,7 +241,7 @@ export declare class Users extends Service {
204
241
  * @param {string[]} queries
205
242
  * @throws {AppwriteException}
206
243
  * @returns {Promise}
207
- */
244
+ */
208
245
  listLogs(userId: string, queries?: string[]): Promise<Models.LogList>;
209
246
  /**
210
247
  * List User Memberships
@@ -214,7 +251,7 @@ export declare class Users extends Service {
214
251
  * @param {string} userId
215
252
  * @throws {AppwriteException}
216
253
  * @returns {Promise}
217
- */
254
+ */
218
255
  listMemberships(userId: string): Promise<Models.MembershipList>;
219
256
  /**
220
257
  * Update Name
@@ -225,7 +262,7 @@ export declare class Users extends Service {
225
262
  * @param {string} name
226
263
  * @throws {AppwriteException}
227
264
  * @returns {Promise}
228
- */
265
+ */
229
266
  updateName<Preferences extends Models.Preferences>(userId: string, name: string): Promise<Models.User<Preferences>>;
230
267
  /**
231
268
  * Update Password
@@ -236,7 +273,7 @@ export declare class Users extends Service {
236
273
  * @param {string} password
237
274
  * @throws {AppwriteException}
238
275
  * @returns {Promise}
239
- */
276
+ */
240
277
  updatePassword<Preferences extends Models.Preferences>(userId: string, password: string): Promise<Models.User<Preferences>>;
241
278
  /**
242
279
  * Update Phone
@@ -247,7 +284,7 @@ export declare class Users extends Service {
247
284
  * @param {string} number
248
285
  * @throws {AppwriteException}
249
286
  * @returns {Promise}
250
- */
287
+ */
251
288
  updatePhone<Preferences extends Models.Preferences>(userId: string, number: string): Promise<Models.User<Preferences>>;
252
289
  /**
253
290
  * Get User Preferences
@@ -257,7 +294,7 @@ export declare class Users extends Service {
257
294
  * @param {string} userId
258
295
  * @throws {AppwriteException}
259
296
  * @returns {Promise}
260
- */
297
+ */
261
298
  getPrefs<Preferences extends Models.Preferences>(userId: string): Promise<Preferences>;
262
299
  /**
263
300
  * Update User Preferences
@@ -270,7 +307,7 @@ export declare class Users extends Service {
270
307
  * @param {object} prefs
271
308
  * @throws {AppwriteException}
272
309
  * @returns {Promise}
273
- */
310
+ */
274
311
  updatePrefs<Preferences extends Models.Preferences>(userId: string, prefs: object): Promise<Preferences>;
275
312
  /**
276
313
  * List User Sessions
@@ -280,7 +317,7 @@ export declare class Users extends Service {
280
317
  * @param {string} userId
281
318
  * @throws {AppwriteException}
282
319
  * @returns {Promise}
283
- */
320
+ */
284
321
  listSessions(userId: string): Promise<Models.SessionList>;
285
322
  /**
286
323
  * Delete User Sessions
@@ -290,7 +327,7 @@ export declare class Users extends Service {
290
327
  * @param {string} userId
291
328
  * @throws {AppwriteException}
292
329
  * @returns {Promise}
293
- */
330
+ */
294
331
  deleteSessions(userId: string): Promise<{}>;
295
332
  /**
296
333
  * Delete User Session
@@ -301,7 +338,7 @@ export declare class Users extends Service {
301
338
  * @param {string} sessionId
302
339
  * @throws {AppwriteException}
303
340
  * @returns {Promise}
304
- */
341
+ */
305
342
  deleteSession(userId: string, sessionId: string): Promise<{}>;
306
343
  /**
307
344
  * Update User Status
@@ -313,7 +350,7 @@ export declare class Users extends Service {
313
350
  * @param {boolean} status
314
351
  * @throws {AppwriteException}
315
352
  * @returns {Promise}
316
- */
353
+ */
317
354
  updateStatus<Preferences extends Models.Preferences>(userId: string, status: boolean): Promise<Models.User<Preferences>>;
318
355
  /**
319
356
  * Update Email Verification
@@ -324,7 +361,7 @@ export declare class Users extends Service {
324
361
  * @param {boolean} emailVerification
325
362
  * @throws {AppwriteException}
326
363
  * @returns {Promise}
327
- */
364
+ */
328
365
  updateEmailVerification<Preferences extends Models.Preferences>(userId: string, emailVerification: boolean): Promise<Models.User<Preferences>>;
329
366
  /**
330
367
  * Update Phone Verification
@@ -335,6 +372,6 @@ export declare class Users extends Service {
335
372
  * @param {boolean} phoneVerification
336
373
  * @throws {AppwriteException}
337
374
  * @returns {Promise}
338
- */
375
+ */
339
376
  updatePhoneVerification<Preferences extends Models.Preferences>(userId: string, phoneVerification: boolean): Promise<Models.User<Preferences>>;
340
377
  }
@@ -0,0 +1,97 @@
1
+ import { Service } from '../service';
2
+ import { Client } from '../client';
3
+ import type { Models } from '../models';
4
+ export declare class Vcs extends Service {
5
+ constructor(client: Client);
6
+ /**
7
+ * List Repositories
8
+ *
9
+ *
10
+ * @param {string} installationId
11
+ * @param {string} search
12
+ * @throws {AppwriteException}
13
+ * @returns {Promise}
14
+ */
15
+ listRepositories(installationId: string, search?: string): Promise<Models.ProviderRepositoryList>;
16
+ /**
17
+ * Create repository
18
+ *
19
+ *
20
+ * @param {string} installationId
21
+ * @param {string} name
22
+ * @param {boolean} xprivate
23
+ * @throws {AppwriteException}
24
+ * @returns {Promise}
25
+ */
26
+ createRepository(installationId: string, name: string, xprivate: boolean): Promise<Models.ProviderRepository>;
27
+ /**
28
+ * Get repository
29
+ *
30
+ *
31
+ * @param {string} installationId
32
+ * @param {string} providerRepositoryId
33
+ * @throws {AppwriteException}
34
+ * @returns {Promise}
35
+ */
36
+ getRepository(installationId: string, providerRepositoryId: string): Promise<Models.ProviderRepository>;
37
+ /**
38
+ * List Repository Branches
39
+ *
40
+ *
41
+ * @param {string} installationId
42
+ * @param {string} providerRepositoryId
43
+ * @throws {AppwriteException}
44
+ * @returns {Promise}
45
+ */
46
+ listRepositoryBranches(installationId: string, providerRepositoryId: string): Promise<Models.BranchList>;
47
+ /**
48
+ * Detect runtime settings from source code
49
+ *
50
+ *
51
+ * @param {string} installationId
52
+ * @param {string} providerRepositoryId
53
+ * @param {string} providerRootDirectory
54
+ * @throws {AppwriteException}
55
+ * @returns {Promise}
56
+ */
57
+ createRepositoryDetection(installationId: string, providerRepositoryId: string, providerRootDirectory?: string): Promise<Models.Detection>;
58
+ /**
59
+ * Authorize external deployment
60
+ *
61
+ *
62
+ * @param {string} installationId
63
+ * @param {string} repositoryId
64
+ * @param {string} providerPullRequestId
65
+ * @throws {AppwriteException}
66
+ * @returns {Promise}
67
+ */
68
+ updateExternalDeployments(installationId: string, repositoryId: string, providerPullRequestId: string): Promise<{}>;
69
+ /**
70
+ * List installations
71
+ *
72
+ *
73
+ * @param {string[]} queries
74
+ * @param {string} search
75
+ * @throws {AppwriteException}
76
+ * @returns {Promise}
77
+ */
78
+ listInstallations(queries?: string[], search?: string): Promise<Models.InstallationList>;
79
+ /**
80
+ * Get installation
81
+ *
82
+ *
83
+ * @param {string} installationId
84
+ * @throws {AppwriteException}
85
+ * @returns {Promise}
86
+ */
87
+ getInstallation(installationId: string): Promise<Models.Installation>;
88
+ /**
89
+ * Delete Installation
90
+ *
91
+ *
92
+ * @param {string} installationId
93
+ * @throws {AppwriteException}
94
+ * @returns {Promise}
95
+ */
96
+ deleteInstallation(installationId: string): Promise<{}>;
97
+ }
package/.travis.yml DELETED
@@ -1,32 +0,0 @@
1
- language: node_js
2
- node_js:
3
- - "14.16"
4
-
5
- jobs:
6
- include:
7
- - stage: NPM RC Release
8
- if: tag == *-RC*
9
- node_js: "14.16"
10
- script:
11
- - npm install
12
- - npm run build
13
- - echo "Deploying RC to NPM..."
14
- deploy:
15
- provider: npm
16
- email: $NPM_EMAIL
17
- api_key: $NPM_API_KEY
18
- tag: next
19
- - stage: NPM Release
20
- if: tag != *-RC*
21
- node_js: "14.16"
22
- script:
23
- - npm install
24
- - npm run build
25
- - echo "Deploying to NPM..."
26
- deploy:
27
- provider: npm
28
- email: $NPM_EMAIL
29
- api_key: $NPM_API_KEY
30
- skip_cleanup: true
31
- on:
32
- tags: true
@@ -1,18 +0,0 @@
1
- import { Client, Projects } from "@appwrite.io/console";
2
-
3
- const client = new Client();
4
-
5
- const projects = new Projects(client);
6
-
7
- client
8
- .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint
9
- .setProject('5df5acd0d48c2') // Your project ID
10
- ;
11
-
12
- const promise = projects.updateDomainVerification('[PROJECT_ID]', '[DOMAIN_ID]');
13
-
14
- promise.then(function (response) {
15
- console.log(response); // Success
16
- }, function (error) {
17
- console.log(error); // Failure
18
- });