@appwrite.io/console 8.1.0 → 8.1.1

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 (898) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/sdk.js +1 -1
  3. package/dist/cjs/sdk.js.map +1 -0
  4. package/dist/esm/sdk.js +29705 -0
  5. package/dist/esm/sdk.js.map +1 -0
  6. package/dist/iife/sdk.js +33515 -0
  7. package/package.json +5 -1
  8. package/types/channel.d.ts +74 -0
  9. package/types/client.d.ts +302 -0
  10. package/types/enums/adapter.d.ts +4 -0
  11. package/types/enums/api-service.d.ts +15 -0
  12. package/types/enums/api.d.ts +5 -0
  13. package/types/enums/appwrite-migration-resource.d.ts +27 -0
  14. package/types/enums/attribute-status.d.ts +7 -0
  15. package/types/enums/auth-method.d.ts +9 -0
  16. package/types/enums/authentication-factor.d.ts +6 -0
  17. package/types/enums/authenticator-type.d.ts +3 -0
  18. package/types/enums/backup-services.d.ts +8 -0
  19. package/types/enums/billing-plan-group.d.ts +5 -0
  20. package/types/enums/browser-permission.d.ts +22 -0
  21. package/types/enums/browser.d.ts +16 -0
  22. package/types/enums/build-runtime.d.ts +88 -0
  23. package/types/enums/column-status.d.ts +7 -0
  24. package/types/enums/compression.d.ts +5 -0
  25. package/types/enums/console-resource-type.d.ts +3 -0
  26. package/types/enums/credit-card.d.ts +19 -0
  27. package/types/enums/database-type.d.ts +6 -0
  28. package/types/enums/databases-index-type.d.ts +6 -0
  29. package/types/enums/deployment-download-type.d.ts +4 -0
  30. package/types/enums/deployment-status.d.ts +8 -0
  31. package/types/enums/domain-purchase-status.d.ts +6 -0
  32. package/types/enums/domain-transfer-status-enum.d.ts +10 -0
  33. package/types/enums/email-template-locale.d.ts +133 -0
  34. package/types/enums/email-template-type.d.ts +9 -0
  35. package/types/enums/execution-method.d.ts +9 -0
  36. package/types/enums/execution-status.d.ts +7 -0
  37. package/types/enums/execution-trigger.d.ts +5 -0
  38. package/types/enums/filter-type.d.ts +4 -0
  39. package/types/enums/firebase-migration-resource.d.ts +12 -0
  40. package/types/enums/flag.d.ts +197 -0
  41. package/types/enums/framework.d.ts +17 -0
  42. package/types/enums/frameworks.d.ts +17 -0
  43. package/types/enums/health-antivirus-status.d.ts +5 -0
  44. package/types/enums/health-check-status.d.ts +4 -0
  45. package/types/enums/image-format.d.ts +9 -0
  46. package/types/enums/image-gravity.d.ts +11 -0
  47. package/types/enums/index-status.d.ts +7 -0
  48. package/types/enums/message-priority.d.ts +4 -0
  49. package/types/enums/message-status.d.ts +7 -0
  50. package/types/enums/messaging-provider-type.d.ts +5 -0
  51. package/types/enums/n-host-migration-resource.d.ts +13 -0
  52. package/types/enums/name.d.ts +15 -0
  53. package/types/enums/o-auth-provider.d.ts +41 -0
  54. package/types/enums/order-by.d.ts +4 -0
  55. package/types/enums/password-hash.d.ts +13 -0
  56. package/types/enums/platform-type.d.ts +17 -0
  57. package/types/enums/platform.d.ts +4 -0
  58. package/types/enums/project-usage-range.d.ts +4 -0
  59. package/types/enums/proxy-resource-type.d.ts +4 -0
  60. package/types/enums/proxy-rule-deployment-resource-type.d.ts +4 -0
  61. package/types/enums/proxy-rule-status.d.ts +6 -0
  62. package/types/enums/region.d.ts +8 -0
  63. package/types/enums/registration-type.d.ts +6 -0
  64. package/types/enums/relation-mutate.d.ts +5 -0
  65. package/types/enums/relationship-type.d.ts +6 -0
  66. package/types/enums/resource-type.d.ts +6 -0
  67. package/types/enums/runtime.d.ts +88 -0
  68. package/types/enums/runtimes.d.ts +88 -0
  69. package/types/enums/scopes.d.ts +81 -0
  70. package/types/enums/sms-template-locale.d.ts +133 -0
  71. package/types/enums/sms-template-type.d.ts +6 -0
  72. package/types/enums/smtp-encryption.d.ts +5 -0
  73. package/types/enums/smtp-secure.d.ts +4 -0
  74. package/types/enums/status-code.d.ts +6 -0
  75. package/types/enums/status.d.ts +3 -0
  76. package/types/enums/supabase-migration-resource.d.ts +13 -0
  77. package/types/enums/tables-db-index-type.d.ts +6 -0
  78. package/types/enums/template-reference-type.d.ts +5 -0
  79. package/types/enums/theme.d.ts +4 -0
  80. package/types/enums/timezone.d.ts +421 -0
  81. package/types/enums/usage-range.d.ts +5 -0
  82. package/types/enums/use-cases.d.ts +16 -0
  83. package/types/enums/vcs-detection-type.d.ts +4 -0
  84. package/types/enums/vcs-reference-type.d.ts +5 -0
  85. package/types/id.d.ts +20 -0
  86. package/{src/index.ts → types/index.d.ts} +1 -1
  87. package/{src/models.ts → types/models.d.ts} +268 -518
  88. package/types/operator.d.ts +180 -0
  89. package/{src/permission.ts → types/permission.d.ts} +6 -20
  90. package/types/query.d.ts +442 -0
  91. package/{src/role.ts → types/role.d.ts} +28 -58
  92. package/types/service.d.ts +11 -0
  93. package/types/services/account.d.ts +1536 -0
  94. package/types/services/activities.d.ts +46 -0
  95. package/types/services/assistant.d.ts +24 -0
  96. package/{src/services/avatars.ts → types/services/avatars.d.ts} +91 -525
  97. package/types/services/backups.d.ts +277 -0
  98. package/types/services/console.d.ts +248 -0
  99. package/types/services/databases.d.ts +2435 -0
  100. package/types/services/domains.d.ts +1527 -0
  101. package/types/services/functions.d.ts +842 -0
  102. package/types/services/graphql.d.ts +43 -0
  103. package/types/services/health.d.ts +475 -0
  104. package/types/services/locale.d.ts +64 -0
  105. package/types/services/messaging.d.ts +1989 -0
  106. package/types/services/migrations.d.ts +417 -0
  107. package/types/services/organizations.d.ts +1009 -0
  108. package/types/services/project.d.ts +148 -0
  109. package/types/services/projects.d.ts +1626 -0
  110. package/types/services/proxy.d.ts +190 -0
  111. package/types/services/realtime.d.ts +134 -0
  112. package/types/services/sites.d.ts +800 -0
  113. package/types/services/storage.d.ts +467 -0
  114. package/types/services/tables-db.d.ts +2352 -0
  115. package/types/services/teams.d.ts +366 -0
  116. package/types/services/tokens.d.ts +119 -0
  117. package/types/services/users.d.ts +1208 -0
  118. package/types/services/vcs.d.ts +252 -0
  119. package/types/services/webhooks.d.ts +165 -0
  120. package/.github/workflows/autoclose.yml +0 -11
  121. package/.github/workflows/publish.yml +0 -43
  122. package/CHANGELOG.md +0 -169
  123. package/docs/examples/account/create-anonymous-session.md +0 -13
  124. package/docs/examples/account/create-billing-address.md +0 -20
  125. package/docs/examples/account/create-email-password-session.md +0 -16
  126. package/docs/examples/account/create-email-token.md +0 -17
  127. package/docs/examples/account/create-email-verification.md +0 -15
  128. package/docs/examples/account/create-jwt.md +0 -15
  129. package/docs/examples/account/create-key.md +0 -17
  130. package/docs/examples/account/create-magic-url-token.md +0 -18
  131. package/docs/examples/account/create-mfa-authenticator.md +0 -15
  132. package/docs/examples/account/create-mfa-challenge.md +0 -15
  133. package/docs/examples/account/create-mfa-recovery-codes.md +0 -13
  134. package/docs/examples/account/create-o-auth-2-session.md +0 -17
  135. package/docs/examples/account/create-o-auth-2-token.md +0 -17
  136. package/docs/examples/account/create-payment-method.md +0 -13
  137. package/docs/examples/account/create-phone-token.md +0 -16
  138. package/docs/examples/account/create-phone-verification.md +0 -13
  139. package/docs/examples/account/create-push-target.md +0 -17
  140. package/docs/examples/account/create-recovery.md +0 -16
  141. package/docs/examples/account/create-session.md +0 -16
  142. package/docs/examples/account/create-verification.md +0 -15
  143. package/docs/examples/account/create.md +0 -18
  144. package/docs/examples/account/delete-billing-address.md +0 -15
  145. package/docs/examples/account/delete-identity.md +0 -15
  146. package/docs/examples/account/delete-key.md +0 -15
  147. package/docs/examples/account/delete-mfa-authenticator.md +0 -15
  148. package/docs/examples/account/delete-payment-method.md +0 -15
  149. package/docs/examples/account/delete-push-target.md +0 -15
  150. package/docs/examples/account/delete-session.md +0 -15
  151. package/docs/examples/account/delete-sessions.md +0 -13
  152. package/docs/examples/account/delete.md +0 -13
  153. package/docs/examples/account/get-billing-address.md +0 -15
  154. package/docs/examples/account/get-coupon.md +0 -15
  155. package/docs/examples/account/get-key.md +0 -15
  156. package/docs/examples/account/get-mfa-recovery-codes.md +0 -13
  157. package/docs/examples/account/get-payment-method.md +0 -15
  158. package/docs/examples/account/get-prefs.md +0 -13
  159. package/docs/examples/account/get-session.md +0 -15
  160. package/docs/examples/account/get.md +0 -13
  161. package/docs/examples/account/list-billing-addresses.md +0 -15
  162. package/docs/examples/account/list-identities.md +0 -16
  163. package/docs/examples/account/list-invoices.md +0 -15
  164. package/docs/examples/account/list-keys.md +0 -15
  165. package/docs/examples/account/list-logs.md +0 -16
  166. package/docs/examples/account/list-mfa-factors.md +0 -13
  167. package/docs/examples/account/list-payment-methods.md +0 -15
  168. package/docs/examples/account/list-sessions.md +0 -13
  169. package/docs/examples/account/update-billing-address.md +0 -21
  170. package/docs/examples/account/update-email-verification.md +0 -16
  171. package/docs/examples/account/update-email.md +0 -16
  172. package/docs/examples/account/update-key.md +0 -18
  173. package/docs/examples/account/update-magic-url-session.md +0 -16
  174. package/docs/examples/account/update-mfa-authenticator.md +0 -16
  175. package/docs/examples/account/update-mfa-challenge.md +0 -16
  176. package/docs/examples/account/update-mfa-recovery-codes.md +0 -13
  177. package/docs/examples/account/update-mfa.md +0 -15
  178. package/docs/examples/account/update-name.md +0 -15
  179. package/docs/examples/account/update-password.md +0 -16
  180. package/docs/examples/account/update-payment-method-mandate-options.md +0 -15
  181. package/docs/examples/account/update-payment-method-provider.md +0 -18
  182. package/docs/examples/account/update-payment-method.md +0 -18
  183. package/docs/examples/account/update-phone-session.md +0 -16
  184. package/docs/examples/account/update-phone-verification.md +0 -16
  185. package/docs/examples/account/update-phone.md +0 -16
  186. package/docs/examples/account/update-prefs.md +0 -19
  187. package/docs/examples/account/update-push-target.md +0 -16
  188. package/docs/examples/account/update-recovery.md +0 -17
  189. package/docs/examples/account/update-session.md +0 -15
  190. package/docs/examples/account/update-status.md +0 -13
  191. package/docs/examples/account/update-verification.md +0 -16
  192. package/docs/examples/activities/get-event.md +0 -15
  193. package/docs/examples/activities/list-events.md +0 -15
  194. package/docs/examples/assistant/chat.md +0 -15
  195. package/docs/examples/avatars/get-browser.md +0 -18
  196. package/docs/examples/avatars/get-credit-card.md +0 -18
  197. package/docs/examples/avatars/get-favicon.md +0 -15
  198. package/docs/examples/avatars/get-flag.md +0 -18
  199. package/docs/examples/avatars/get-image.md +0 -17
  200. package/docs/examples/avatars/get-initials.md +0 -18
  201. package/docs/examples/avatars/get-qr.md +0 -18
  202. package/docs/examples/avatars/get-screenshot.md +0 -37
  203. package/docs/examples/backups/create-archive.md +0 -16
  204. package/docs/examples/backups/create-policy.md +0 -21
  205. package/docs/examples/backups/create-restoration.md +0 -18
  206. package/docs/examples/backups/delete-archive.md +0 -15
  207. package/docs/examples/backups/delete-policy.md +0 -15
  208. package/docs/examples/backups/get-archive.md +0 -15
  209. package/docs/examples/backups/get-policy.md +0 -15
  210. package/docs/examples/backups/get-restoration.md +0 -15
  211. package/docs/examples/backups/list-archives.md +0 -15
  212. package/docs/examples/backups/list-policies.md +0 -15
  213. package/docs/examples/backups/list-restorations.md +0 -15
  214. package/docs/examples/backups/update-policy.md +0 -19
  215. package/docs/examples/console/create-program-membership.md +0 -15
  216. package/docs/examples/console/create-source.md +0 -19
  217. package/docs/examples/console/get-campaign.md +0 -15
  218. package/docs/examples/console/get-coupon.md +0 -15
  219. package/docs/examples/console/get-plan.md +0 -15
  220. package/docs/examples/console/get-plans.md +0 -15
  221. package/docs/examples/console/get-program.md +0 -15
  222. package/docs/examples/console/get-resource.md +0 -16
  223. package/docs/examples/console/list-regions.md +0 -13
  224. package/docs/examples/console/suggest-columns.md +0 -19
  225. package/docs/examples/console/suggest-indexes.md +0 -18
  226. package/docs/examples/console/variables.md +0 -13
  227. package/docs/examples/databases/create-boolean-attribute.md +0 -20
  228. package/docs/examples/databases/create-collection.md +0 -22
  229. package/docs/examples/databases/create-datetime-attribute.md +0 -20
  230. package/docs/examples/databases/create-document.md +0 -26
  231. package/docs/examples/databases/create-documents.md +0 -18
  232. package/docs/examples/databases/create-email-attribute.md +0 -20
  233. package/docs/examples/databases/create-enum-attribute.md +0 -21
  234. package/docs/examples/databases/create-float-attribute.md +0 -22
  235. package/docs/examples/databases/create-index.md +0 -21
  236. package/docs/examples/databases/create-integer-attribute.md +0 -22
  237. package/docs/examples/databases/create-ip-attribute.md +0 -20
  238. package/docs/examples/databases/create-line-attribute.md +0 -19
  239. package/docs/examples/databases/create-longtext-attribute.md +0 -21
  240. package/docs/examples/databases/create-mediumtext-attribute.md +0 -21
  241. package/docs/examples/databases/create-operations.md +0 -26
  242. package/docs/examples/databases/create-point-attribute.md +0 -19
  243. package/docs/examples/databases/create-polygon-attribute.md +0 -19
  244. package/docs/examples/databases/create-relationship-attribute.md +0 -22
  245. package/docs/examples/databases/create-string-attribute.md +0 -22
  246. package/docs/examples/databases/create-text-attribute.md +0 -21
  247. package/docs/examples/databases/create-transaction.md +0 -15
  248. package/docs/examples/databases/create-url-attribute.md +0 -20
  249. package/docs/examples/databases/create-varchar-attribute.md +0 -22
  250. package/docs/examples/databases/create.md +0 -17
  251. package/docs/examples/databases/decrement-document-attribute.md +0 -21
  252. package/docs/examples/databases/delete-attribute.md +0 -17
  253. package/docs/examples/databases/delete-collection.md +0 -16
  254. package/docs/examples/databases/delete-document.md +0 -18
  255. package/docs/examples/databases/delete-documents.md +0 -18
  256. package/docs/examples/databases/delete-index.md +0 -17
  257. package/docs/examples/databases/delete-transaction.md +0 -15
  258. package/docs/examples/databases/delete.md +0 -15
  259. package/docs/examples/databases/get-attribute.md +0 -17
  260. package/docs/examples/databases/get-collection-usage.md +0 -17
  261. package/docs/examples/databases/get-collection.md +0 -16
  262. package/docs/examples/databases/get-document.md +0 -19
  263. package/docs/examples/databases/get-index.md +0 -17
  264. package/docs/examples/databases/get-transaction.md +0 -15
  265. package/docs/examples/databases/get-usage.md +0 -16
  266. package/docs/examples/databases/get.md +0 -15
  267. package/docs/examples/databases/increment-document-attribute.md +0 -21
  268. package/docs/examples/databases/list-attributes.md +0 -18
  269. package/docs/examples/databases/list-collection-logs.md +0 -17
  270. package/docs/examples/databases/list-collections.md +0 -18
  271. package/docs/examples/databases/list-document-logs.md +0 -18
  272. package/docs/examples/databases/list-documents.md +0 -20
  273. package/docs/examples/databases/list-indexes.md +0 -18
  274. package/docs/examples/databases/list-logs.md +0 -16
  275. package/docs/examples/databases/list-transactions.md +0 -15
  276. package/docs/examples/databases/list-usage.md +0 -15
  277. package/docs/examples/databases/list.md +0 -17
  278. package/docs/examples/databases/update-boolean-attribute.md +0 -20
  279. package/docs/examples/databases/update-collection.md +0 -20
  280. package/docs/examples/databases/update-datetime-attribute.md +0 -20
  281. package/docs/examples/databases/update-document.md +0 -26
  282. package/docs/examples/databases/update-documents.md +0 -25
  283. package/docs/examples/databases/update-email-attribute.md +0 -20
  284. package/docs/examples/databases/update-enum-attribute.md +0 -21
  285. package/docs/examples/databases/update-float-attribute.md +0 -22
  286. package/docs/examples/databases/update-integer-attribute.md +0 -22
  287. package/docs/examples/databases/update-ip-attribute.md +0 -20
  288. package/docs/examples/databases/update-line-attribute.md +0 -20
  289. package/docs/examples/databases/update-longtext-attribute.md +0 -20
  290. package/docs/examples/databases/update-mediumtext-attribute.md +0 -20
  291. package/docs/examples/databases/update-point-attribute.md +0 -20
  292. package/docs/examples/databases/update-polygon-attribute.md +0 -20
  293. package/docs/examples/databases/update-relationship-attribute.md +0 -19
  294. package/docs/examples/databases/update-string-attribute.md +0 -21
  295. package/docs/examples/databases/update-text-attribute.md +0 -20
  296. package/docs/examples/databases/update-transaction.md +0 -17
  297. package/docs/examples/databases/update-url-attribute.md +0 -20
  298. package/docs/examples/databases/update-varchar-attribute.md +0 -21
  299. package/docs/examples/databases/update.md +0 -17
  300. package/docs/examples/databases/upsert-document.md +0 -26
  301. package/docs/examples/databases/upsert-documents.md +0 -18
  302. package/docs/examples/domains/create-preset-google-workspace.md +0 -15
  303. package/docs/examples/domains/create-preset-i-cloud.md +0 -15
  304. package/docs/examples/domains/create-preset-mailgun.md +0 -15
  305. package/docs/examples/domains/create-preset-outlook.md +0 -15
  306. package/docs/examples/domains/create-preset-proton-mail.md +0 -15
  307. package/docs/examples/domains/create-preset-zoho.md +0 -15
  308. package/docs/examples/domains/create-purchase.md +0 -26
  309. package/docs/examples/domains/create-record-a.md +0 -19
  310. package/docs/examples/domains/create-record-aaaa.md +0 -19
  311. package/docs/examples/domains/create-record-alias.md +0 -19
  312. package/docs/examples/domains/create-record-caa.md +0 -19
  313. package/docs/examples/domains/create-record-cname.md +0 -19
  314. package/docs/examples/domains/create-record-https.md +0 -19
  315. package/docs/examples/domains/create-record-mx.md +0 -20
  316. package/docs/examples/domains/create-record-ns.md +0 -19
  317. package/docs/examples/domains/create-record-srv.md +0 -22
  318. package/docs/examples/domains/create-record-txt.md +0 -19
  319. package/docs/examples/domains/create-transfer-in.md +0 -19
  320. package/docs/examples/domains/create-transfer-out.md +0 -16
  321. package/docs/examples/domains/create.md +0 -16
  322. package/docs/examples/domains/delete-record.md +0 -16
  323. package/docs/examples/domains/delete.md +0 -15
  324. package/docs/examples/domains/get-preset-google-workspace.md +0 -15
  325. package/docs/examples/domains/get-preset-i-cloud.md +0 -15
  326. package/docs/examples/domains/get-preset-mailgun.md +0 -15
  327. package/docs/examples/domains/get-preset-outlook.md +0 -15
  328. package/docs/examples/domains/get-preset-proton-mail.md +0 -15
  329. package/docs/examples/domains/get-preset-zoho.md +0 -15
  330. package/docs/examples/domains/get-price.md +0 -17
  331. package/docs/examples/domains/get-record.md +0 -16
  332. package/docs/examples/domains/get-transfer-status.md +0 -15
  333. package/docs/examples/domains/get-zone.md +0 -15
  334. package/docs/examples/domains/get.md +0 -15
  335. package/docs/examples/domains/list-records.md +0 -16
  336. package/docs/examples/domains/list-suggestions.md +0 -20
  337. package/docs/examples/domains/list.md +0 -16
  338. package/docs/examples/domains/update-auto-renewal.md +0 -16
  339. package/docs/examples/domains/update-nameservers.md +0 -15
  340. package/docs/examples/domains/update-purchase.md +0 -16
  341. package/docs/examples/domains/update-record-a.md +0 -20
  342. package/docs/examples/domains/update-record-aaaa.md +0 -20
  343. package/docs/examples/domains/update-record-alias.md +0 -20
  344. package/docs/examples/domains/update-record-caa.md +0 -20
  345. package/docs/examples/domains/update-record-cname.md +0 -20
  346. package/docs/examples/domains/update-record-https.md +0 -20
  347. package/docs/examples/domains/update-record-mx.md +0 -21
  348. package/docs/examples/domains/update-record-ns.md +0 -20
  349. package/docs/examples/domains/update-record-srv.md +0 -23
  350. package/docs/examples/domains/update-record-txt.md +0 -20
  351. package/docs/examples/domains/update-team.md +0 -16
  352. package/docs/examples/domains/update-transfer-in.md +0 -16
  353. package/docs/examples/domains/update-zone.md +0 -16
  354. package/docs/examples/functions/create-deployment.md +0 -19
  355. package/docs/examples/functions/create-duplicate-deployment.md +0 -17
  356. package/docs/examples/functions/create-execution.md +0 -21
  357. package/docs/examples/functions/create-template-deployment.md +0 -21
  358. package/docs/examples/functions/create-variable.md +0 -18
  359. package/docs/examples/functions/create-vcs-deployment.md +0 -18
  360. package/docs/examples/functions/create.md +0 -34
  361. package/docs/examples/functions/delete-deployment.md +0 -16
  362. package/docs/examples/functions/delete-execution.md +0 -16
  363. package/docs/examples/functions/delete-variable.md +0 -16
  364. package/docs/examples/functions/delete.md +0 -15
  365. package/docs/examples/functions/get-deployment-download.md +0 -17
  366. package/docs/examples/functions/get-deployment.md +0 -16
  367. package/docs/examples/functions/get-execution.md +0 -16
  368. package/docs/examples/functions/get-template.md +0 -15
  369. package/docs/examples/functions/get-usage.md +0 -16
  370. package/docs/examples/functions/get-variable.md +0 -16
  371. package/docs/examples/functions/get.md +0 -15
  372. package/docs/examples/functions/list-deployments.md +0 -18
  373. package/docs/examples/functions/list-executions.md +0 -17
  374. package/docs/examples/functions/list-runtimes.md +0 -13
  375. package/docs/examples/functions/list-specifications.md +0 -13
  376. package/docs/examples/functions/list-templates.md +0 -19
  377. package/docs/examples/functions/list-usage.md +0 -15
  378. package/docs/examples/functions/list-variables.md +0 -15
  379. package/docs/examples/functions/list.md +0 -17
  380. package/docs/examples/functions/update-deployment-status.md +0 -16
  381. package/docs/examples/functions/update-function-deployment.md +0 -16
  382. package/docs/examples/functions/update-variable.md +0 -19
  383. package/docs/examples/functions/update.md +0 -34
  384. package/docs/examples/graphql/mutation.md +0 -15
  385. package/docs/examples/graphql/query.md +0 -15
  386. package/docs/examples/health/get-antivirus.md +0 -13
  387. package/docs/examples/health/get-cache.md +0 -13
  388. package/docs/examples/health/get-certificate.md +0 -15
  389. package/docs/examples/health/get-console-pausing.md +0 -16
  390. package/docs/examples/health/get-db.md +0 -13
  391. package/docs/examples/health/get-failed-jobs.md +0 -16
  392. package/docs/examples/health/get-pub-sub.md +0 -13
  393. package/docs/examples/health/get-queue-audits.md +0 -15
  394. package/docs/examples/health/get-queue-billing-project-aggregation.md +0 -15
  395. package/docs/examples/health/get-queue-billing-team-aggregation.md +0 -15
  396. package/docs/examples/health/get-queue-builds.md +0 -15
  397. package/docs/examples/health/get-queue-certificates.md +0 -15
  398. package/docs/examples/health/get-queue-databases.md +0 -16
  399. package/docs/examples/health/get-queue-deletes.md +0 -15
  400. package/docs/examples/health/get-queue-functions.md +0 -15
  401. package/docs/examples/health/get-queue-logs.md +0 -15
  402. package/docs/examples/health/get-queue-mails.md +0 -15
  403. package/docs/examples/health/get-queue-messaging.md +0 -15
  404. package/docs/examples/health/get-queue-migrations.md +0 -15
  405. package/docs/examples/health/get-queue-priority-builds.md +0 -15
  406. package/docs/examples/health/get-queue-region-manager.md +0 -15
  407. package/docs/examples/health/get-queue-stats-resources.md +0 -15
  408. package/docs/examples/health/get-queue-threats.md +0 -15
  409. package/docs/examples/health/get-queue-usage.md +0 -15
  410. package/docs/examples/health/get-queue-webhooks.md +0 -15
  411. package/docs/examples/health/get-storage-local.md +0 -13
  412. package/docs/examples/health/get-storage.md +0 -13
  413. package/docs/examples/health/get-time.md +0 -13
  414. package/docs/examples/health/get.md +0 -13
  415. package/docs/examples/locale/get.md +0 -13
  416. package/docs/examples/locale/list-codes.md +0 -13
  417. package/docs/examples/locale/list-continents.md +0 -13
  418. package/docs/examples/locale/list-countries-eu.md +0 -13
  419. package/docs/examples/locale/list-countries-phones.md +0 -13
  420. package/docs/examples/locale/list-countries.md +0 -13
  421. package/docs/examples/locale/list-currencies.md +0 -13
  422. package/docs/examples/locale/list-languages.md +0 -13
  423. package/docs/examples/messaging/create-apns-provider.md +0 -22
  424. package/docs/examples/messaging/create-email.md +0 -26
  425. package/docs/examples/messaging/create-fcm-provider.md +0 -18
  426. package/docs/examples/messaging/create-mailgun-provider.md +0 -24
  427. package/docs/examples/messaging/create-msg-91-provider.md +0 -20
  428. package/docs/examples/messaging/create-push.md +0 -33
  429. package/docs/examples/messaging/create-resend-provider.md +0 -22
  430. package/docs/examples/messaging/create-sendgrid-provider.md +0 -22
  431. package/docs/examples/messaging/create-sms.md +0 -21
  432. package/docs/examples/messaging/create-smtp-provider.md +0 -28
  433. package/docs/examples/messaging/create-subscriber.md +0 -17
  434. package/docs/examples/messaging/create-telesign-provider.md +0 -20
  435. package/docs/examples/messaging/create-textmagic-provider.md +0 -20
  436. package/docs/examples/messaging/create-topic.md +0 -17
  437. package/docs/examples/messaging/create-twilio-provider.md +0 -20
  438. package/docs/examples/messaging/create-vonage-provider.md +0 -20
  439. package/docs/examples/messaging/delete-provider.md +0 -15
  440. package/docs/examples/messaging/delete-subscriber.md +0 -16
  441. package/docs/examples/messaging/delete-topic.md +0 -15
  442. package/docs/examples/messaging/delete.md +0 -15
  443. package/docs/examples/messaging/get-message.md +0 -15
  444. package/docs/examples/messaging/get-provider.md +0 -15
  445. package/docs/examples/messaging/get-subscriber.md +0 -16
  446. package/docs/examples/messaging/get-topic.md +0 -15
  447. package/docs/examples/messaging/list-message-logs.md +0 -17
  448. package/docs/examples/messaging/list-messages.md +0 -17
  449. package/docs/examples/messaging/list-provider-logs.md +0 -17
  450. package/docs/examples/messaging/list-providers.md +0 -17
  451. package/docs/examples/messaging/list-subscriber-logs.md +0 -17
  452. package/docs/examples/messaging/list-subscribers.md +0 -18
  453. package/docs/examples/messaging/list-targets.md +0 -17
  454. package/docs/examples/messaging/list-topic-logs.md +0 -17
  455. package/docs/examples/messaging/list-topics.md +0 -17
  456. package/docs/examples/messaging/update-apns-provider.md +0 -22
  457. package/docs/examples/messaging/update-email.md +0 -26
  458. package/docs/examples/messaging/update-fcm-provider.md +0 -18
  459. package/docs/examples/messaging/update-mailgun-provider.md +0 -24
  460. package/docs/examples/messaging/update-msg-91-provider.md +0 -20
  461. package/docs/examples/messaging/update-push.md +0 -33
  462. package/docs/examples/messaging/update-resend-provider.md +0 -22
  463. package/docs/examples/messaging/update-sendgrid-provider.md +0 -22
  464. package/docs/examples/messaging/update-sms.md +0 -21
  465. package/docs/examples/messaging/update-smtp-provider.md +0 -28
  466. package/docs/examples/messaging/update-telesign-provider.md +0 -20
  467. package/docs/examples/messaging/update-textmagic-provider.md +0 -20
  468. package/docs/examples/messaging/update-topic.md +0 -17
  469. package/docs/examples/messaging/update-twilio-provider.md +0 -20
  470. package/docs/examples/messaging/update-vonage-provider.md +0 -20
  471. package/docs/examples/migrations/create-appwrite-migration.md +0 -18
  472. package/docs/examples/migrations/create-csv-export.md +0 -23
  473. package/docs/examples/migrations/create-csv-import.md +0 -18
  474. package/docs/examples/migrations/create-firebase-migration.md +0 -16
  475. package/docs/examples/migrations/create-n-host-migration.md +0 -22
  476. package/docs/examples/migrations/create-supabase-migration.md +0 -21
  477. package/docs/examples/migrations/delete.md +0 -15
  478. package/docs/examples/migrations/get-appwrite-report.md +0 -18
  479. package/docs/examples/migrations/get-firebase-report.md +0 -16
  480. package/docs/examples/migrations/get-n-host-report.md +0 -22
  481. package/docs/examples/migrations/get-supabase-report.md +0 -21
  482. package/docs/examples/migrations/get.md +0 -15
  483. package/docs/examples/migrations/list.md +0 -17
  484. package/docs/examples/migrations/retry.md +0 -15
  485. package/docs/examples/organizations/add-credit.md +0 -16
  486. package/docs/examples/organizations/cancel-downgrade.md +0 -15
  487. package/docs/examples/organizations/create-downgrade-feedback.md +0 -19
  488. package/docs/examples/organizations/create-invoice-payment.md +0 -17
  489. package/docs/examples/organizations/create-key.md +0 -18
  490. package/docs/examples/organizations/create.md +0 -24
  491. package/docs/examples/organizations/delete-backup-payment-method.md +0 -15
  492. package/docs/examples/organizations/delete-billing-address.md +0 -15
  493. package/docs/examples/organizations/delete-default-payment-method.md +0 -15
  494. package/docs/examples/organizations/delete-key.md +0 -16
  495. package/docs/examples/organizations/delete.md +0 -15
  496. package/docs/examples/organizations/estimation-create-organization.md +0 -19
  497. package/docs/examples/organizations/estimation-delete-organization.md +0 -15
  498. package/docs/examples/organizations/estimation-update-plan.md +0 -18
  499. package/docs/examples/organizations/get-aggregation.md +0 -18
  500. package/docs/examples/organizations/get-available-credits.md +0 -15
  501. package/docs/examples/organizations/get-billing-address.md +0 -16
  502. package/docs/examples/organizations/get-credit.md +0 -16
  503. package/docs/examples/organizations/get-invoice-download.md +0 -16
  504. package/docs/examples/organizations/get-invoice-view.md +0 -16
  505. package/docs/examples/organizations/get-invoice.md +0 -16
  506. package/docs/examples/organizations/get-key.md +0 -16
  507. package/docs/examples/organizations/get-payment-method.md +0 -16
  508. package/docs/examples/organizations/get-plan.md +0 -15
  509. package/docs/examples/organizations/get-scopes.md +0 -16
  510. package/docs/examples/organizations/get-usage.md +0 -17
  511. package/docs/examples/organizations/list-aggregations.md +0 -16
  512. package/docs/examples/organizations/list-credits.md +0 -16
  513. package/docs/examples/organizations/list-invoices.md +0 -16
  514. package/docs/examples/organizations/list-keys.md +0 -16
  515. package/docs/examples/organizations/list-regions.md +0 -15
  516. package/docs/examples/organizations/list.md +0 -16
  517. package/docs/examples/organizations/set-backup-payment-method.md +0 -16
  518. package/docs/examples/organizations/set-billing-address.md +0 -16
  519. package/docs/examples/organizations/set-billing-email.md +0 -16
  520. package/docs/examples/organizations/set-billing-tax-id.md +0 -16
  521. package/docs/examples/organizations/set-default-payment-method.md +0 -16
  522. package/docs/examples/organizations/update-budget.md +0 -17
  523. package/docs/examples/organizations/update-key.md +0 -19
  524. package/docs/examples/organizations/update-plan.md +0 -22
  525. package/docs/examples/organizations/validate-invoice.md +0 -16
  526. package/docs/examples/organizations/validate-payment.md +0 -16
  527. package/docs/examples/project/create-variable.md +0 -18
  528. package/docs/examples/project/delete-variable.md +0 -15
  529. package/docs/examples/project/get-usage.md +0 -17
  530. package/docs/examples/project/get-variable.md +0 -15
  531. package/docs/examples/project/list-variables.md +0 -16
  532. package/docs/examples/project/update-variable.md +0 -18
  533. package/docs/examples/projects/create-dev-key.md +0 -17
  534. package/docs/examples/projects/create-jwt.md +0 -17
  535. package/docs/examples/projects/create-key.md +0 -19
  536. package/docs/examples/projects/create-platform.md +0 -20
  537. package/docs/examples/projects/create-schedule.md +0 -20
  538. package/docs/examples/projects/create-smtp-test.md +0 -24
  539. package/docs/examples/projects/create.md +0 -27
  540. package/docs/examples/projects/delete-dev-key.md +0 -16
  541. package/docs/examples/projects/delete-email-template.md +0 -17
  542. package/docs/examples/projects/delete-key.md +0 -16
  543. package/docs/examples/projects/delete-platform.md +0 -16
  544. package/docs/examples/projects/delete-sms-template.md +0 -17
  545. package/docs/examples/projects/delete.md +0 -15
  546. package/docs/examples/projects/get-dev-key.md +0 -16
  547. package/docs/examples/projects/get-email-template.md +0 -17
  548. package/docs/examples/projects/get-key.md +0 -16
  549. package/docs/examples/projects/get-platform.md +0 -16
  550. package/docs/examples/projects/get-schedule.md +0 -16
  551. package/docs/examples/projects/get-sms-template.md +0 -17
  552. package/docs/examples/projects/get.md +0 -15
  553. package/docs/examples/projects/list-dev-keys.md +0 -16
  554. package/docs/examples/projects/list-keys.md +0 -17
  555. package/docs/examples/projects/list-platforms.md +0 -16
  556. package/docs/examples/projects/list-schedules.md +0 -17
  557. package/docs/examples/projects/list.md +0 -17
  558. package/docs/examples/projects/update-api-status-all.md +0 -16
  559. package/docs/examples/projects/update-api-status.md +0 -17
  560. package/docs/examples/projects/update-auth-duration.md +0 -16
  561. package/docs/examples/projects/update-auth-limit.md +0 -16
  562. package/docs/examples/projects/update-auth-password-dictionary.md +0 -16
  563. package/docs/examples/projects/update-auth-password-history.md +0 -16
  564. package/docs/examples/projects/update-auth-sessions-limit.md +0 -16
  565. package/docs/examples/projects/update-auth-status.md +0 -17
  566. package/docs/examples/projects/update-console-access.md +0 -15
  567. package/docs/examples/projects/update-dev-key.md +0 -18
  568. package/docs/examples/projects/update-email-template.md +0 -22
  569. package/docs/examples/projects/update-key.md +0 -19
  570. package/docs/examples/projects/update-labels.md +0 -16
  571. package/docs/examples/projects/update-memberships-privacy.md +0 -18
  572. package/docs/examples/projects/update-mock-numbers.md +0 -16
  573. package/docs/examples/projects/update-o-auth-2.md +0 -19
  574. package/docs/examples/projects/update-personal-data-check.md +0 -16
  575. package/docs/examples/projects/update-platform.md +0 -20
  576. package/docs/examples/projects/update-service-status-all.md +0 -16
  577. package/docs/examples/projects/update-service-status.md +0 -17
  578. package/docs/examples/projects/update-session-alerts.md +0 -16
  579. package/docs/examples/projects/update-session-invalidation.md +0 -16
  580. package/docs/examples/projects/update-sms-template.md +0 -18
  581. package/docs/examples/projects/update-smtp.md +0 -24
  582. package/docs/examples/projects/update-status.md +0 -16
  583. package/docs/examples/projects/update-team.md +0 -16
  584. package/docs/examples/projects/update.md +0 -25
  585. package/docs/examples/proxy/create-api-rule.md +0 -15
  586. package/docs/examples/proxy/create-function-rule.md +0 -17
  587. package/docs/examples/proxy/create-redirect-rule.md +0 -19
  588. package/docs/examples/proxy/create-site-rule.md +0 -17
  589. package/docs/examples/proxy/delete-rule.md +0 -15
  590. package/docs/examples/proxy/get-rule.md +0 -15
  591. package/docs/examples/proxy/list-rules.md +0 -17
  592. package/docs/examples/proxy/update-rule-verification.md +0 -15
  593. package/docs/examples/sites/create-deployment.md +0 -20
  594. package/docs/examples/sites/create-duplicate-deployment.md +0 -16
  595. package/docs/examples/sites/create-template-deployment.md +0 -21
  596. package/docs/examples/sites/create-variable.md +0 -18
  597. package/docs/examples/sites/create-vcs-deployment.md +0 -18
  598. package/docs/examples/sites/create.md +0 -35
  599. package/docs/examples/sites/delete-deployment.md +0 -16
  600. package/docs/examples/sites/delete-log.md +0 -16
  601. package/docs/examples/sites/delete-variable.md +0 -16
  602. package/docs/examples/sites/delete.md +0 -15
  603. package/docs/examples/sites/get-deployment-download.md +0 -17
  604. package/docs/examples/sites/get-deployment.md +0 -16
  605. package/docs/examples/sites/get-log.md +0 -16
  606. package/docs/examples/sites/get-template.md +0 -15
  607. package/docs/examples/sites/get-usage.md +0 -16
  608. package/docs/examples/sites/get-variable.md +0 -16
  609. package/docs/examples/sites/get.md +0 -15
  610. package/docs/examples/sites/list-deployments.md +0 -18
  611. package/docs/examples/sites/list-frameworks.md +0 -13
  612. package/docs/examples/sites/list-logs.md +0 -17
  613. package/docs/examples/sites/list-specifications.md +0 -13
  614. package/docs/examples/sites/list-templates.md +0 -18
  615. package/docs/examples/sites/list-usage.md +0 -15
  616. package/docs/examples/sites/list-variables.md +0 -15
  617. package/docs/examples/sites/list.md +0 -17
  618. package/docs/examples/sites/update-deployment-status.md +0 -16
  619. package/docs/examples/sites/update-site-deployment.md +0 -16
  620. package/docs/examples/sites/update-variable.md +0 -19
  621. package/docs/examples/sites/update.md +0 -35
  622. package/docs/examples/storage/create-bucket.md +0 -25
  623. package/docs/examples/storage/create-file.md +0 -18
  624. package/docs/examples/storage/delete-bucket.md +0 -15
  625. package/docs/examples/storage/delete-file.md +0 -16
  626. package/docs/examples/storage/get-bucket-usage.md +0 -16
  627. package/docs/examples/storage/get-bucket.md +0 -15
  628. package/docs/examples/storage/get-file-download.md +0 -17
  629. package/docs/examples/storage/get-file-preview.md +0 -28
  630. package/docs/examples/storage/get-file-view.md +0 -17
  631. package/docs/examples/storage/get-file.md +0 -16
  632. package/docs/examples/storage/get-usage.md +0 -15
  633. package/docs/examples/storage/list-buckets.md +0 -17
  634. package/docs/examples/storage/list-files.md +0 -18
  635. package/docs/examples/storage/update-bucket.md +0 -25
  636. package/docs/examples/storage/update-file.md +0 -18
  637. package/docs/examples/tablesdb/create-boolean-column.md +0 -20
  638. package/docs/examples/tablesdb/create-datetime-column.md +0 -20
  639. package/docs/examples/tablesdb/create-email-column.md +0 -20
  640. package/docs/examples/tablesdb/create-enum-column.md +0 -21
  641. package/docs/examples/tablesdb/create-float-column.md +0 -22
  642. package/docs/examples/tablesdb/create-index.md +0 -21
  643. package/docs/examples/tablesdb/create-integer-column.md +0 -22
  644. package/docs/examples/tablesdb/create-ip-column.md +0 -20
  645. package/docs/examples/tablesdb/create-line-column.md +0 -19
  646. package/docs/examples/tablesdb/create-longtext-column.md +0 -21
  647. package/docs/examples/tablesdb/create-mediumtext-column.md +0 -21
  648. package/docs/examples/tablesdb/create-operations.md +0 -26
  649. package/docs/examples/tablesdb/create-point-column.md +0 -19
  650. package/docs/examples/tablesdb/create-polygon-column.md +0 -19
  651. package/docs/examples/tablesdb/create-relationship-column.md +0 -22
  652. package/docs/examples/tablesdb/create-row.md +0 -26
  653. package/docs/examples/tablesdb/create-rows.md +0 -18
  654. package/docs/examples/tablesdb/create-string-column.md +0 -22
  655. package/docs/examples/tablesdb/create-table.md +0 -22
  656. package/docs/examples/tablesdb/create-text-column.md +0 -21
  657. package/docs/examples/tablesdb/create-transaction.md +0 -15
  658. package/docs/examples/tablesdb/create-url-column.md +0 -20
  659. package/docs/examples/tablesdb/create-varchar-column.md +0 -22
  660. package/docs/examples/tablesdb/create.md +0 -17
  661. package/docs/examples/tablesdb/decrement-row-column.md +0 -21
  662. package/docs/examples/tablesdb/delete-column.md +0 -17
  663. package/docs/examples/tablesdb/delete-index.md +0 -17
  664. package/docs/examples/tablesdb/delete-row.md +0 -18
  665. package/docs/examples/tablesdb/delete-rows.md +0 -18
  666. package/docs/examples/tablesdb/delete-table.md +0 -16
  667. package/docs/examples/tablesdb/delete-transaction.md +0 -15
  668. package/docs/examples/tablesdb/delete.md +0 -15
  669. package/docs/examples/tablesdb/get-column.md +0 -17
  670. package/docs/examples/tablesdb/get-index.md +0 -17
  671. package/docs/examples/tablesdb/get-row.md +0 -19
  672. package/docs/examples/tablesdb/get-table-usage.md +0 -17
  673. package/docs/examples/tablesdb/get-table.md +0 -16
  674. package/docs/examples/tablesdb/get-transaction.md +0 -15
  675. package/docs/examples/tablesdb/get-usage.md +0 -16
  676. package/docs/examples/tablesdb/get.md +0 -15
  677. package/docs/examples/tablesdb/increment-row-column.md +0 -21
  678. package/docs/examples/tablesdb/list-columns.md +0 -18
  679. package/docs/examples/tablesdb/list-indexes.md +0 -18
  680. package/docs/examples/tablesdb/list-row-logs.md +0 -18
  681. package/docs/examples/tablesdb/list-rows.md +0 -20
  682. package/docs/examples/tablesdb/list-table-logs.md +0 -17
  683. package/docs/examples/tablesdb/list-tables.md +0 -18
  684. package/docs/examples/tablesdb/list-transactions.md +0 -15
  685. package/docs/examples/tablesdb/list-usage.md +0 -15
  686. package/docs/examples/tablesdb/list.md +0 -17
  687. package/docs/examples/tablesdb/update-boolean-column.md +0 -20
  688. package/docs/examples/tablesdb/update-datetime-column.md +0 -20
  689. package/docs/examples/tablesdb/update-email-column.md +0 -20
  690. package/docs/examples/tablesdb/update-enum-column.md +0 -21
  691. package/docs/examples/tablesdb/update-float-column.md +0 -22
  692. package/docs/examples/tablesdb/update-integer-column.md +0 -22
  693. package/docs/examples/tablesdb/update-ip-column.md +0 -20
  694. package/docs/examples/tablesdb/update-line-column.md +0 -20
  695. package/docs/examples/tablesdb/update-longtext-column.md +0 -20
  696. package/docs/examples/tablesdb/update-mediumtext-column.md +0 -20
  697. package/docs/examples/tablesdb/update-point-column.md +0 -20
  698. package/docs/examples/tablesdb/update-polygon-column.md +0 -20
  699. package/docs/examples/tablesdb/update-relationship-column.md +0 -19
  700. package/docs/examples/tablesdb/update-row.md +0 -26
  701. package/docs/examples/tablesdb/update-rows.md +0 -25
  702. package/docs/examples/tablesdb/update-string-column.md +0 -21
  703. package/docs/examples/tablesdb/update-table.md +0 -20
  704. package/docs/examples/tablesdb/update-text-column.md +0 -20
  705. package/docs/examples/tablesdb/update-transaction.md +0 -17
  706. package/docs/examples/tablesdb/update-url-column.md +0 -20
  707. package/docs/examples/tablesdb/update-varchar-column.md +0 -21
  708. package/docs/examples/tablesdb/update.md +0 -17
  709. package/docs/examples/tablesdb/upsert-row.md +0 -26
  710. package/docs/examples/tablesdb/upsert-rows.md +0 -18
  711. package/docs/examples/teams/create-membership.md +0 -21
  712. package/docs/examples/teams/create.md +0 -17
  713. package/docs/examples/teams/delete-membership.md +0 -16
  714. package/docs/examples/teams/delete.md +0 -15
  715. package/docs/examples/teams/get-membership.md +0 -16
  716. package/docs/examples/teams/get-prefs.md +0 -15
  717. package/docs/examples/teams/get.md +0 -15
  718. package/docs/examples/teams/list-logs.md +0 -17
  719. package/docs/examples/teams/list-memberships.md +0 -18
  720. package/docs/examples/teams/list.md +0 -17
  721. package/docs/examples/teams/update-membership-status.md +0 -18
  722. package/docs/examples/teams/update-membership.md +0 -17
  723. package/docs/examples/teams/update-name.md +0 -16
  724. package/docs/examples/teams/update-prefs.md +0 -16
  725. package/docs/examples/tokens/create-file-token.md +0 -17
  726. package/docs/examples/tokens/delete.md +0 -15
  727. package/docs/examples/tokens/get.md +0 -15
  728. package/docs/examples/tokens/list.md +0 -18
  729. package/docs/examples/tokens/update.md +0 -16
  730. package/docs/examples/users/create-argon-2-user.md +0 -18
  731. package/docs/examples/users/create-bcrypt-user.md +0 -18
  732. package/docs/examples/users/create-jwt.md +0 -17
  733. package/docs/examples/users/create-md-5-user.md +0 -18
  734. package/docs/examples/users/create-mfa-recovery-codes.md +0 -15
  735. package/docs/examples/users/create-ph-pass-user.md +0 -18
  736. package/docs/examples/users/create-scrypt-modified-user.md +0 -21
  737. package/docs/examples/users/create-scrypt-user.md +0 -23
  738. package/docs/examples/users/create-session.md +0 -15
  739. package/docs/examples/users/create-sha-user.md +0 -19
  740. package/docs/examples/users/create-target.md +0 -20
  741. package/docs/examples/users/create-token.md +0 -17
  742. package/docs/examples/users/create.md +0 -19
  743. package/docs/examples/users/delete-identity.md +0 -15
  744. package/docs/examples/users/delete-mfa-authenticator.md +0 -16
  745. package/docs/examples/users/delete-session.md +0 -16
  746. package/docs/examples/users/delete-sessions.md +0 -15
  747. package/docs/examples/users/delete-target.md +0 -16
  748. package/docs/examples/users/delete.md +0 -15
  749. package/docs/examples/users/get-mfa-recovery-codes.md +0 -15
  750. package/docs/examples/users/get-prefs.md +0 -15
  751. package/docs/examples/users/get-target.md +0 -16
  752. package/docs/examples/users/get-usage.md +0 -15
  753. package/docs/examples/users/get.md +0 -15
  754. package/docs/examples/users/list-identities.md +0 -17
  755. package/docs/examples/users/list-logs.md +0 -17
  756. package/docs/examples/users/list-memberships.md +0 -18
  757. package/docs/examples/users/list-mfa-factors.md +0 -15
  758. package/docs/examples/users/list-sessions.md +0 -16
  759. package/docs/examples/users/list-targets.md +0 -17
  760. package/docs/examples/users/list.md +0 -17
  761. package/docs/examples/users/update-email-verification.md +0 -16
  762. package/docs/examples/users/update-email.md +0 -16
  763. package/docs/examples/users/update-impersonator.md +0 -16
  764. package/docs/examples/users/update-labels.md +0 -16
  765. package/docs/examples/users/update-mfa-recovery-codes.md +0 -15
  766. package/docs/examples/users/update-mfa.md +0 -16
  767. package/docs/examples/users/update-name.md +0 -16
  768. package/docs/examples/users/update-password.md +0 -16
  769. package/docs/examples/users/update-phone-verification.md +0 -16
  770. package/docs/examples/users/update-phone.md +0 -16
  771. package/docs/examples/users/update-prefs.md +0 -16
  772. package/docs/examples/users/update-status.md +0 -16
  773. package/docs/examples/users/update-target.md +0 -19
  774. package/docs/examples/vcs/create-repository-detection.md +0 -18
  775. package/docs/examples/vcs/create-repository.md +0 -17
  776. package/docs/examples/vcs/delete-installation.md +0 -15
  777. package/docs/examples/vcs/get-installation.md +0 -15
  778. package/docs/examples/vcs/get-repository-contents.md +0 -18
  779. package/docs/examples/vcs/get-repository.md +0 -16
  780. package/docs/examples/vcs/list-installations.md +0 -17
  781. package/docs/examples/vcs/list-repositories.md +0 -18
  782. package/docs/examples/vcs/list-repository-branches.md +0 -16
  783. package/docs/examples/vcs/update-external-deployments.md +0 -17
  784. package/docs/examples/webhooks/create.md +0 -22
  785. package/docs/examples/webhooks/delete.md +0 -15
  786. package/docs/examples/webhooks/get.md +0 -15
  787. package/docs/examples/webhooks/list.md +0 -16
  788. package/docs/examples/webhooks/update-signature.md +0 -15
  789. package/docs/examples/webhooks/update.md +0 -22
  790. package/rollup.config.js +0 -44
  791. package/src/channel.ts +0 -158
  792. package/src/client.ts +0 -1085
  793. package/src/enums/adapter.ts +0 -4
  794. package/src/enums/api-service.ts +0 -15
  795. package/src/enums/api.ts +0 -5
  796. package/src/enums/appwrite-migration-resource.ts +0 -27
  797. package/src/enums/attribute-status.ts +0 -7
  798. package/src/enums/auth-method.ts +0 -9
  799. package/src/enums/authentication-factor.ts +0 -6
  800. package/src/enums/authenticator-type.ts +0 -3
  801. package/src/enums/backup-services.ts +0 -8
  802. package/src/enums/billing-plan-group.ts +0 -5
  803. package/src/enums/browser-permission.ts +0 -22
  804. package/src/enums/browser.ts +0 -16
  805. package/src/enums/build-runtime.ts +0 -88
  806. package/src/enums/column-status.ts +0 -7
  807. package/src/enums/compression.ts +0 -5
  808. package/src/enums/console-resource-type.ts +0 -3
  809. package/src/enums/credit-card.ts +0 -19
  810. package/src/enums/database-type.ts +0 -6
  811. package/src/enums/databases-index-type.ts +0 -6
  812. package/src/enums/deployment-download-type.ts +0 -4
  813. package/src/enums/deployment-status.ts +0 -8
  814. package/src/enums/domain-purchase-status.ts +0 -6
  815. package/src/enums/domain-transfer-status-enum.ts +0 -10
  816. package/src/enums/email-template-locale.ts +0 -133
  817. package/src/enums/email-template-type.ts +0 -9
  818. package/src/enums/execution-method.ts +0 -9
  819. package/src/enums/execution-status.ts +0 -7
  820. package/src/enums/execution-trigger.ts +0 -5
  821. package/src/enums/filter-type.ts +0 -4
  822. package/src/enums/firebase-migration-resource.ts +0 -12
  823. package/src/enums/flag.ts +0 -197
  824. package/src/enums/framework.ts +0 -17
  825. package/src/enums/frameworks.ts +0 -17
  826. package/src/enums/health-antivirus-status.ts +0 -5
  827. package/src/enums/health-check-status.ts +0 -4
  828. package/src/enums/image-format.ts +0 -9
  829. package/src/enums/image-gravity.ts +0 -11
  830. package/src/enums/index-status.ts +0 -7
  831. package/src/enums/message-priority.ts +0 -4
  832. package/src/enums/message-status.ts +0 -7
  833. package/src/enums/messaging-provider-type.ts +0 -5
  834. package/src/enums/n-host-migration-resource.ts +0 -13
  835. package/src/enums/name.ts +0 -15
  836. package/src/enums/o-auth-provider.ts +0 -41
  837. package/src/enums/order-by.ts +0 -4
  838. package/src/enums/password-hash.ts +0 -13
  839. package/src/enums/platform-type.ts +0 -17
  840. package/src/enums/platform.ts +0 -4
  841. package/src/enums/project-usage-range.ts +0 -4
  842. package/src/enums/proxy-resource-type.ts +0 -4
  843. package/src/enums/proxy-rule-deployment-resource-type.ts +0 -4
  844. package/src/enums/proxy-rule-status.ts +0 -6
  845. package/src/enums/region.ts +0 -8
  846. package/src/enums/registration-type.ts +0 -6
  847. package/src/enums/relation-mutate.ts +0 -5
  848. package/src/enums/relationship-type.ts +0 -6
  849. package/src/enums/resource-type.ts +0 -6
  850. package/src/enums/runtime.ts +0 -88
  851. package/src/enums/runtimes.ts +0 -88
  852. package/src/enums/scopes.ts +0 -81
  853. package/src/enums/sms-template-locale.ts +0 -133
  854. package/src/enums/sms-template-type.ts +0 -6
  855. package/src/enums/smtp-encryption.ts +0 -5
  856. package/src/enums/smtp-secure.ts +0 -4
  857. package/src/enums/status-code.ts +0 -6
  858. package/src/enums/status.ts +0 -3
  859. package/src/enums/supabase-migration-resource.ts +0 -13
  860. package/src/enums/tables-db-index-type.ts +0 -6
  861. package/src/enums/template-reference-type.ts +0 -5
  862. package/src/enums/theme.ts +0 -4
  863. package/src/enums/timezone.ts +0 -421
  864. package/src/enums/usage-range.ts +0 -5
  865. package/src/enums/use-cases.ts +0 -16
  866. package/src/enums/vcs-detection-type.ts +0 -4
  867. package/src/enums/vcs-reference-type.ts +0 -5
  868. package/src/id.ts +0 -47
  869. package/src/operator.ts +0 -308
  870. package/src/query.ts +0 -576
  871. package/src/service.ts +0 -30
  872. package/src/services/account.ts +0 -4293
  873. package/src/services/activities.ts +0 -116
  874. package/src/services/assistant.ts +0 -67
  875. package/src/services/backups.ts +0 -754
  876. package/src/services/console.ts +0 -678
  877. package/src/services/databases.ts +0 -6376
  878. package/src/services/domains.ts +0 -4064
  879. package/src/services/functions.ts +0 -2224
  880. package/src/services/graphql.ts +0 -124
  881. package/src/services/health.ts +0 -1296
  882. package/src/services/locale.ts +0 -198
  883. package/src/services/messaging.ts +0 -5194
  884. package/src/services/migrations.ts +0 -1207
  885. package/src/services/organizations.ts +0 -2742
  886. package/src/services/project.ts +0 -404
  887. package/src/services/projects.ts +0 -4431
  888. package/src/services/proxy.ts +0 -532
  889. package/src/services/realtime.ts +0 -537
  890. package/src/services/sites.ts +0 -2131
  891. package/src/services/storage.ts +0 -1196
  892. package/src/services/tables-db.ts +0 -6256
  893. package/src/services/teams.ts +0 -959
  894. package/src/services/tokens.ts +0 -315
  895. package/src/services/users.ts +0 -3324
  896. package/src/services/vcs.ts +0 -676
  897. package/src/services/webhooks.ts +0 -451
  898. package/tsconfig.json +0 -24
@@ -1,4064 +0,0 @@
1
- import { Service } from '../service';
2
- import { AppwriteException, Client, type Payload, UploadProgress } from '../client';
3
- import type { Models } from '../models';
4
-
5
- import { RegistrationType } from '../enums/registration-type';
6
- import { FilterType } from '../enums/filter-type';
7
-
8
- export class Domains {
9
- client: Client;
10
-
11
- constructor(client: Client) {
12
- this.client = client;
13
- }
14
-
15
- /**
16
- * List all domains registered for this project. This endpoint supports pagination.
17
- *
18
- * @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on attributes such as domain name, teamInternalId, expiration, etc.
19
- * @param {string} params.search - Search term to filter your list results. Max length: 256 chars.
20
- * @throws {AppwriteException}
21
- * @returns {Promise<Models.DomainsList>}
22
- */
23
- list(params?: { queries?: string[], search?: string }): Promise<Models.DomainsList>;
24
- /**
25
- * List all domains registered for this project. This endpoint supports pagination.
26
- *
27
- * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on attributes such as domain name, teamInternalId, expiration, etc.
28
- * @param {string} search - Search term to filter your list results. Max length: 256 chars.
29
- * @throws {AppwriteException}
30
- * @returns {Promise<Models.DomainsList>}
31
- * @deprecated Use the object parameter style method for a better developer experience.
32
- */
33
- list(queries?: string[], search?: string): Promise<Models.DomainsList>;
34
- list(
35
- paramsOrFirst?: { queries?: string[], search?: string } | string[],
36
- ...rest: [(string)?]
37
- ): Promise<Models.DomainsList> {
38
- let params: { queries?: string[], search?: string };
39
-
40
- if (!paramsOrFirst || (paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
41
- params = (paramsOrFirst || {}) as { queries?: string[], search?: string };
42
- } else {
43
- params = {
44
- queries: paramsOrFirst as string[],
45
- search: rest[0] as string
46
- };
47
- }
48
-
49
- const queries = params.queries;
50
- const search = params.search;
51
-
52
-
53
- const apiPath = '/domains';
54
- const payload: Payload = {};
55
- if (typeof queries !== 'undefined') {
56
- payload['queries'] = queries;
57
- }
58
- if (typeof search !== 'undefined') {
59
- payload['search'] = search;
60
- }
61
- const uri = new URL(this.client.config.endpoint + apiPath);
62
-
63
- const apiHeaders: { [header: string]: string } = {
64
- }
65
-
66
- return this.client.call(
67
- 'get',
68
- uri,
69
- apiHeaders,
70
- payload
71
- );
72
- }
73
-
74
- /**
75
- * Create a new domain. Before creating a domain, you need to ensure that your DNS provider is properly configured. After creating the domain, you can use the verification endpoint to check if the domain is ready to be used.
76
- *
77
- * @param {string} params.teamId - Team unique ID.
78
- * @param {string} params.domain - Domain name (e.g. "example.com").
79
- * @throws {AppwriteException}
80
- * @returns {Promise<Models.Domain>}
81
- */
82
- create(params: { teamId: string, domain: string }): Promise<Models.Domain>;
83
- /**
84
- * Create a new domain. Before creating a domain, you need to ensure that your DNS provider is properly configured. After creating the domain, you can use the verification endpoint to check if the domain is ready to be used.
85
- *
86
- * @param {string} teamId - Team unique ID.
87
- * @param {string} domain - Domain name (e.g. "example.com").
88
- * @throws {AppwriteException}
89
- * @returns {Promise<Models.Domain>}
90
- * @deprecated Use the object parameter style method for a better developer experience.
91
- */
92
- create(teamId: string, domain: string): Promise<Models.Domain>;
93
- create(
94
- paramsOrFirst: { teamId: string, domain: string } | string,
95
- ...rest: [(string)?]
96
- ): Promise<Models.Domain> {
97
- let params: { teamId: string, domain: string };
98
-
99
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
100
- params = (paramsOrFirst || {}) as { teamId: string, domain: string };
101
- } else {
102
- params = {
103
- teamId: paramsOrFirst as string,
104
- domain: rest[0] as string
105
- };
106
- }
107
-
108
- const teamId = params.teamId;
109
- const domain = params.domain;
110
-
111
- if (typeof teamId === 'undefined') {
112
- throw new AppwriteException('Missing required parameter: "teamId"');
113
- }
114
- if (typeof domain === 'undefined') {
115
- throw new AppwriteException('Missing required parameter: "domain"');
116
- }
117
-
118
- const apiPath = '/domains';
119
- const payload: Payload = {};
120
- if (typeof teamId !== 'undefined') {
121
- payload['teamId'] = teamId;
122
- }
123
- if (typeof domain !== 'undefined') {
124
- payload['domain'] = domain;
125
- }
126
- const uri = new URL(this.client.config.endpoint + apiPath);
127
-
128
- const apiHeaders: { [header: string]: string } = {
129
- 'content-type': 'application/json',
130
- }
131
-
132
- return this.client.call(
133
- 'post',
134
- uri,
135
- apiHeaders,
136
- payload
137
- );
138
- }
139
-
140
- /**
141
- * Get the registration price for a domain name.
142
- *
143
- * @param {string} params.domain - Domain name to get price for.
144
- * @param {number} params.periodYears - Number of years to calculate the domain price for. Must be at least 1.
145
- * @param {RegistrationType} params.registrationType - Type of registration pricing to fetch. Allowed values: new, transfer, renewal, trade.
146
- * @throws {AppwriteException}
147
- * @returns {Promise<Models.DomainPrice>}
148
- */
149
- getPrice(params: { domain: string, periodYears?: number, registrationType?: RegistrationType }): Promise<Models.DomainPrice>;
150
- /**
151
- * Get the registration price for a domain name.
152
- *
153
- * @param {string} domain - Domain name to get price for.
154
- * @param {number} periodYears - Number of years to calculate the domain price for. Must be at least 1.
155
- * @param {RegistrationType} registrationType - Type of registration pricing to fetch. Allowed values: new, transfer, renewal, trade.
156
- * @throws {AppwriteException}
157
- * @returns {Promise<Models.DomainPrice>}
158
- * @deprecated Use the object parameter style method for a better developer experience.
159
- */
160
- getPrice(domain: string, periodYears?: number, registrationType?: RegistrationType): Promise<Models.DomainPrice>;
161
- getPrice(
162
- paramsOrFirst: { domain: string, periodYears?: number, registrationType?: RegistrationType } | string,
163
- ...rest: [(number)?, (RegistrationType)?]
164
- ): Promise<Models.DomainPrice> {
165
- let params: { domain: string, periodYears?: number, registrationType?: RegistrationType };
166
-
167
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
168
- params = (paramsOrFirst || {}) as { domain: string, periodYears?: number, registrationType?: RegistrationType };
169
- } else {
170
- params = {
171
- domain: paramsOrFirst as string,
172
- periodYears: rest[0] as number,
173
- registrationType: rest[1] as RegistrationType
174
- };
175
- }
176
-
177
- const domain = params.domain;
178
- const periodYears = params.periodYears;
179
- const registrationType = params.registrationType;
180
-
181
- if (typeof domain === 'undefined') {
182
- throw new AppwriteException('Missing required parameter: "domain"');
183
- }
184
-
185
- const apiPath = '/domains/price';
186
- const payload: Payload = {};
187
- if (typeof domain !== 'undefined') {
188
- payload['domain'] = domain;
189
- }
190
- if (typeof periodYears !== 'undefined') {
191
- payload['periodYears'] = periodYears;
192
- }
193
- if (typeof registrationType !== 'undefined') {
194
- payload['registrationType'] = registrationType;
195
- }
196
- const uri = new URL(this.client.config.endpoint + apiPath);
197
-
198
- const apiHeaders: { [header: string]: string } = {
199
- }
200
-
201
- return this.client.call(
202
- 'get',
203
- uri,
204
- apiHeaders,
205
- payload
206
- );
207
- }
208
-
209
- /**
210
- * Initiate a domain purchase by providing registrant details and a payment method. Authorizes the payment and returns a `clientSecret`. If 3D Secure is required, use the `clientSecret` on the client to complete the authentication challenge. Once authentication is complete (or if none is needed), call the Update Purchase endpoint to capture the payment and finalize the purchase.
211
- *
212
- * @param {string} params.domain - Fully qualified domain name to purchase (for example, example.com).
213
- * @param {string} params.organizationId - Team ID that will own the domain.
214
- * @param {string} params.firstName - Registrant first name used for domain registration.
215
- * @param {string} params.lastName - Registrant last name used for domain registration.
216
- * @param {string} params.email - Registrant email address for registration and notices.
217
- * @param {string} params.phone - Registrant phone number in E.164 format (for example, +15555551234).
218
- * @param {string} params.billingAddressId - Billing address ID used for registration contact details.
219
- * @param {string} params.paymentMethodId - Payment method ID to authorize and capture the purchase.
220
- * @param {string} params.addressLine3 - Additional address line for the registrant (line 3).
221
- * @param {string} params.companyName - Company or organization name for the registrant.
222
- * @param {number} params.periodYears - Registration term in years (1-10).
223
- * @param {boolean} params.autoRenewal - Whether the domain should renew automatically after purchase.
224
- * @throws {AppwriteException}
225
- * @returns {Promise<Models.DomainPurchase>}
226
- */
227
- createPurchase(params: { domain: string, organizationId: string, firstName: string, lastName: string, email: string, phone: string, billingAddressId: string, paymentMethodId: string, addressLine3?: string, companyName?: string, periodYears?: number, autoRenewal?: boolean }): Promise<Models.DomainPurchase>;
228
- /**
229
- * Initiate a domain purchase by providing registrant details and a payment method. Authorizes the payment and returns a `clientSecret`. If 3D Secure is required, use the `clientSecret` on the client to complete the authentication challenge. Once authentication is complete (or if none is needed), call the Update Purchase endpoint to capture the payment and finalize the purchase.
230
- *
231
- * @param {string} domain - Fully qualified domain name to purchase (for example, example.com).
232
- * @param {string} organizationId - Team ID that will own the domain.
233
- * @param {string} firstName - Registrant first name used for domain registration.
234
- * @param {string} lastName - Registrant last name used for domain registration.
235
- * @param {string} email - Registrant email address for registration and notices.
236
- * @param {string} phone - Registrant phone number in E.164 format (for example, +15555551234).
237
- * @param {string} billingAddressId - Billing address ID used for registration contact details.
238
- * @param {string} paymentMethodId - Payment method ID to authorize and capture the purchase.
239
- * @param {string} addressLine3 - Additional address line for the registrant (line 3).
240
- * @param {string} companyName - Company or organization name for the registrant.
241
- * @param {number} periodYears - Registration term in years (1-10).
242
- * @param {boolean} autoRenewal - Whether the domain should renew automatically after purchase.
243
- * @throws {AppwriteException}
244
- * @returns {Promise<Models.DomainPurchase>}
245
- * @deprecated Use the object parameter style method for a better developer experience.
246
- */
247
- createPurchase(domain: string, organizationId: string, firstName: string, lastName: string, email: string, phone: string, billingAddressId: string, paymentMethodId: string, addressLine3?: string, companyName?: string, periodYears?: number, autoRenewal?: boolean): Promise<Models.DomainPurchase>;
248
- createPurchase(
249
- paramsOrFirst: { domain: string, organizationId: string, firstName: string, lastName: string, email: string, phone: string, billingAddressId: string, paymentMethodId: string, addressLine3?: string, companyName?: string, periodYears?: number, autoRenewal?: boolean } | string,
250
- ...rest: [(string)?, (string)?, (string)?, (string)?, (string)?, (string)?, (string)?, (string)?, (string)?, (number)?, (boolean)?]
251
- ): Promise<Models.DomainPurchase> {
252
- let params: { domain: string, organizationId: string, firstName: string, lastName: string, email: string, phone: string, billingAddressId: string, paymentMethodId: string, addressLine3?: string, companyName?: string, periodYears?: number, autoRenewal?: boolean };
253
-
254
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
255
- params = (paramsOrFirst || {}) as { domain: string, organizationId: string, firstName: string, lastName: string, email: string, phone: string, billingAddressId: string, paymentMethodId: string, addressLine3?: string, companyName?: string, periodYears?: number, autoRenewal?: boolean };
256
- } else {
257
- params = {
258
- domain: paramsOrFirst as string,
259
- organizationId: rest[0] as string,
260
- firstName: rest[1] as string,
261
- lastName: rest[2] as string,
262
- email: rest[3] as string,
263
- phone: rest[4] as string,
264
- billingAddressId: rest[5] as string,
265
- paymentMethodId: rest[6] as string,
266
- addressLine3: rest[7] as string,
267
- companyName: rest[8] as string,
268
- periodYears: rest[9] as number,
269
- autoRenewal: rest[10] as boolean
270
- };
271
- }
272
-
273
- const domain = params.domain;
274
- const organizationId = params.organizationId;
275
- const firstName = params.firstName;
276
- const lastName = params.lastName;
277
- const email = params.email;
278
- const phone = params.phone;
279
- const billingAddressId = params.billingAddressId;
280
- const paymentMethodId = params.paymentMethodId;
281
- const addressLine3 = params.addressLine3;
282
- const companyName = params.companyName;
283
- const periodYears = params.periodYears;
284
- const autoRenewal = params.autoRenewal;
285
-
286
- if (typeof domain === 'undefined') {
287
- throw new AppwriteException('Missing required parameter: "domain"');
288
- }
289
- if (typeof organizationId === 'undefined') {
290
- throw new AppwriteException('Missing required parameter: "organizationId"');
291
- }
292
- if (typeof firstName === 'undefined') {
293
- throw new AppwriteException('Missing required parameter: "firstName"');
294
- }
295
- if (typeof lastName === 'undefined') {
296
- throw new AppwriteException('Missing required parameter: "lastName"');
297
- }
298
- if (typeof email === 'undefined') {
299
- throw new AppwriteException('Missing required parameter: "email"');
300
- }
301
- if (typeof phone === 'undefined') {
302
- throw new AppwriteException('Missing required parameter: "phone"');
303
- }
304
- if (typeof billingAddressId === 'undefined') {
305
- throw new AppwriteException('Missing required parameter: "billingAddressId"');
306
- }
307
- if (typeof paymentMethodId === 'undefined') {
308
- throw new AppwriteException('Missing required parameter: "paymentMethodId"');
309
- }
310
-
311
- const apiPath = '/domains/purchases';
312
- const payload: Payload = {};
313
- if (typeof domain !== 'undefined') {
314
- payload['domain'] = domain;
315
- }
316
- if (typeof organizationId !== 'undefined') {
317
- payload['organizationId'] = organizationId;
318
- }
319
- if (typeof firstName !== 'undefined') {
320
- payload['firstName'] = firstName;
321
- }
322
- if (typeof lastName !== 'undefined') {
323
- payload['lastName'] = lastName;
324
- }
325
- if (typeof email !== 'undefined') {
326
- payload['email'] = email;
327
- }
328
- if (typeof phone !== 'undefined') {
329
- payload['phone'] = phone;
330
- }
331
- if (typeof billingAddressId !== 'undefined') {
332
- payload['billingAddressId'] = billingAddressId;
333
- }
334
- if (typeof addressLine3 !== 'undefined') {
335
- payload['addressLine3'] = addressLine3;
336
- }
337
- if (typeof companyName !== 'undefined') {
338
- payload['companyName'] = companyName;
339
- }
340
- if (typeof periodYears !== 'undefined') {
341
- payload['periodYears'] = periodYears;
342
- }
343
- if (typeof autoRenewal !== 'undefined') {
344
- payload['autoRenewal'] = autoRenewal;
345
- }
346
- if (typeof paymentMethodId !== 'undefined') {
347
- payload['paymentMethodId'] = paymentMethodId;
348
- }
349
- const uri = new URL(this.client.config.endpoint + apiPath);
350
-
351
- const apiHeaders: { [header: string]: string } = {
352
- 'content-type': 'application/json',
353
- }
354
-
355
- return this.client.call(
356
- 'post',
357
- uri,
358
- apiHeaders,
359
- payload
360
- );
361
- }
362
-
363
- /**
364
- * Finalize a domain purchase initiated with Create Purchase. Verifies that any required 3D Secure authentication is complete, registers the domain, captures the payment, and provisions default DNS records. Returns a 402 error if authentication is still pending.
365
- *
366
- * @param {string} params.domainId - Domain ID to confirm purchase for.
367
- * @param {string} params.organizationId - Team ID that owns the domain.
368
- * @throws {AppwriteException}
369
- * @returns {Promise<Models.DomainPurchase>}
370
- */
371
- updatePurchase(params: { domainId: string, organizationId: string }): Promise<Models.DomainPurchase>;
372
- /**
373
- * Finalize a domain purchase initiated with Create Purchase. Verifies that any required 3D Secure authentication is complete, registers the domain, captures the payment, and provisions default DNS records. Returns a 402 error if authentication is still pending.
374
- *
375
- * @param {string} domainId - Domain ID to confirm purchase for.
376
- * @param {string} organizationId - Team ID that owns the domain.
377
- * @throws {AppwriteException}
378
- * @returns {Promise<Models.DomainPurchase>}
379
- * @deprecated Use the object parameter style method for a better developer experience.
380
- */
381
- updatePurchase(domainId: string, organizationId: string): Promise<Models.DomainPurchase>;
382
- updatePurchase(
383
- paramsOrFirst: { domainId: string, organizationId: string } | string,
384
- ...rest: [(string)?]
385
- ): Promise<Models.DomainPurchase> {
386
- let params: { domainId: string, organizationId: string };
387
-
388
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
389
- params = (paramsOrFirst || {}) as { domainId: string, organizationId: string };
390
- } else {
391
- params = {
392
- domainId: paramsOrFirst as string,
393
- organizationId: rest[0] as string
394
- };
395
- }
396
-
397
- const domainId = params.domainId;
398
- const organizationId = params.organizationId;
399
-
400
- if (typeof domainId === 'undefined') {
401
- throw new AppwriteException('Missing required parameter: "domainId"');
402
- }
403
- if (typeof organizationId === 'undefined') {
404
- throw new AppwriteException('Missing required parameter: "organizationId"');
405
- }
406
-
407
- const apiPath = '/domains/purchases/{domainId}'.replace('{domainId}', domainId);
408
- const payload: Payload = {};
409
- if (typeof organizationId !== 'undefined') {
410
- payload['organizationId'] = organizationId;
411
- }
412
- const uri = new URL(this.client.config.endpoint + apiPath);
413
-
414
- const apiHeaders: { [header: string]: string } = {
415
- 'content-type': 'application/json',
416
- }
417
-
418
- return this.client.call(
419
- 'patch',
420
- uri,
421
- apiHeaders,
422
- payload
423
- );
424
- }
425
-
426
- /**
427
- * List domain suggestions.
428
- *
429
- * @param {string} params.query - Query to find available domains and suggestions. Max length: 256 chars.
430
- * @param {string[]} params.tlds - TLDs to suggest.
431
- * @param {number} params.limit - Maximum number of suggestions to return.
432
- * @param {FilterType} params.filterType - Filter type: premium, suggestion.
433
- * @param {number} params.priceMax - Filter premium domains by maximum price. Only premium domains at or below this price will be returned. Does not affect regular domain suggestions.
434
- * @param {number} params.priceMin - Filter premium domains by minimum price. Only premium domains at or above this price will be returned. Does not affect regular domain suggestions.
435
- * @throws {AppwriteException}
436
- * @returns {Promise<Models.DomainSuggestionsList>}
437
- */
438
- listSuggestions(params: { query: string, tlds?: string[], limit?: number, filterType?: FilterType, priceMax?: number, priceMin?: number }): Promise<Models.DomainSuggestionsList>;
439
- /**
440
- * List domain suggestions.
441
- *
442
- * @param {string} query - Query to find available domains and suggestions. Max length: 256 chars.
443
- * @param {string[]} tlds - TLDs to suggest.
444
- * @param {number} limit - Maximum number of suggestions to return.
445
- * @param {FilterType} filterType - Filter type: premium, suggestion.
446
- * @param {number} priceMax - Filter premium domains by maximum price. Only premium domains at or below this price will be returned. Does not affect regular domain suggestions.
447
- * @param {number} priceMin - Filter premium domains by minimum price. Only premium domains at or above this price will be returned. Does not affect regular domain suggestions.
448
- * @throws {AppwriteException}
449
- * @returns {Promise<Models.DomainSuggestionsList>}
450
- * @deprecated Use the object parameter style method for a better developer experience.
451
- */
452
- listSuggestions(query: string, tlds?: string[], limit?: number, filterType?: FilterType, priceMax?: number, priceMin?: number): Promise<Models.DomainSuggestionsList>;
453
- listSuggestions(
454
- paramsOrFirst: { query: string, tlds?: string[], limit?: number, filterType?: FilterType, priceMax?: number, priceMin?: number } | string,
455
- ...rest: [(string[])?, (number)?, (FilterType)?, (number)?, (number)?]
456
- ): Promise<Models.DomainSuggestionsList> {
457
- let params: { query: string, tlds?: string[], limit?: number, filterType?: FilterType, priceMax?: number, priceMin?: number };
458
-
459
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
460
- params = (paramsOrFirst || {}) as { query: string, tlds?: string[], limit?: number, filterType?: FilterType, priceMax?: number, priceMin?: number };
461
- } else {
462
- params = {
463
- query: paramsOrFirst as string,
464
- tlds: rest[0] as string[],
465
- limit: rest[1] as number,
466
- filterType: rest[2] as FilterType,
467
- priceMax: rest[3] as number,
468
- priceMin: rest[4] as number
469
- };
470
- }
471
-
472
- const query = params.query;
473
- const tlds = params.tlds;
474
- const limit = params.limit;
475
- const filterType = params.filterType;
476
- const priceMax = params.priceMax;
477
- const priceMin = params.priceMin;
478
-
479
- if (typeof query === 'undefined') {
480
- throw new AppwriteException('Missing required parameter: "query"');
481
- }
482
-
483
- const apiPath = '/domains/suggestions';
484
- const payload: Payload = {};
485
- if (typeof query !== 'undefined') {
486
- payload['query'] = query;
487
- }
488
- if (typeof tlds !== 'undefined') {
489
- payload['tlds'] = tlds;
490
- }
491
- if (typeof limit !== 'undefined') {
492
- payload['limit'] = limit;
493
- }
494
- if (typeof filterType !== 'undefined') {
495
- payload['filterType'] = filterType;
496
- }
497
- if (typeof priceMax !== 'undefined') {
498
- payload['priceMax'] = priceMax;
499
- }
500
- if (typeof priceMin !== 'undefined') {
501
- payload['priceMin'] = priceMin;
502
- }
503
- const uri = new URL(this.client.config.endpoint + apiPath);
504
-
505
- const apiHeaders: { [header: string]: string } = {
506
- }
507
-
508
- return this.client.call(
509
- 'get',
510
- uri,
511
- apiHeaders,
512
- payload
513
- );
514
- }
515
-
516
- /**
517
- * Initiate a domain transfer-in by providing an authorization code, registrant details, and a payment method. Authorizes the payment and returns a `clientSecret`. If 3D Secure is required, use the `clientSecret` on the client to complete the authentication challenge. Once authentication is complete (or if none is needed), call the Update Transfer In endpoint to capture the payment and submit the transfer.
518
- *
519
- * @param {string} params.domain - Domain name to transfer in.
520
- * @param {string} params.organizationId - Organization ID that this domain will belong to.
521
- * @param {string} params.authCode - Authorization code for the domain transfer.
522
- * @param {string} params.paymentMethodId - Payment method ID to authorize and capture the transfer.
523
- * @param {boolean} params.autoRenewal - Whether the domain should renew automatically after transfer.
524
- * @throws {AppwriteException}
525
- * @returns {Promise<Models.DomainPurchase>}
526
- */
527
- createTransferIn(params: { domain: string, organizationId: string, authCode: string, paymentMethodId: string, autoRenewal?: boolean }): Promise<Models.DomainPurchase>;
528
- /**
529
- * Initiate a domain transfer-in by providing an authorization code, registrant details, and a payment method. Authorizes the payment and returns a `clientSecret`. If 3D Secure is required, use the `clientSecret` on the client to complete the authentication challenge. Once authentication is complete (or if none is needed), call the Update Transfer In endpoint to capture the payment and submit the transfer.
530
- *
531
- * @param {string} domain - Domain name to transfer in.
532
- * @param {string} organizationId - Organization ID that this domain will belong to.
533
- * @param {string} authCode - Authorization code for the domain transfer.
534
- * @param {string} paymentMethodId - Payment method ID to authorize and capture the transfer.
535
- * @param {boolean} autoRenewal - Whether the domain should renew automatically after transfer.
536
- * @throws {AppwriteException}
537
- * @returns {Promise<Models.DomainPurchase>}
538
- * @deprecated Use the object parameter style method for a better developer experience.
539
- */
540
- createTransferIn(domain: string, organizationId: string, authCode: string, paymentMethodId: string, autoRenewal?: boolean): Promise<Models.DomainPurchase>;
541
- createTransferIn(
542
- paramsOrFirst: { domain: string, organizationId: string, authCode: string, paymentMethodId: string, autoRenewal?: boolean } | string,
543
- ...rest: [(string)?, (string)?, (string)?, (boolean)?]
544
- ): Promise<Models.DomainPurchase> {
545
- let params: { domain: string, organizationId: string, authCode: string, paymentMethodId: string, autoRenewal?: boolean };
546
-
547
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
548
- params = (paramsOrFirst || {}) as { domain: string, organizationId: string, authCode: string, paymentMethodId: string, autoRenewal?: boolean };
549
- } else {
550
- params = {
551
- domain: paramsOrFirst as string,
552
- organizationId: rest[0] as string,
553
- authCode: rest[1] as string,
554
- paymentMethodId: rest[2] as string,
555
- autoRenewal: rest[3] as boolean
556
- };
557
- }
558
-
559
- const domain = params.domain;
560
- const organizationId = params.organizationId;
561
- const authCode = params.authCode;
562
- const paymentMethodId = params.paymentMethodId;
563
- const autoRenewal = params.autoRenewal;
564
-
565
- if (typeof domain === 'undefined') {
566
- throw new AppwriteException('Missing required parameter: "domain"');
567
- }
568
- if (typeof organizationId === 'undefined') {
569
- throw new AppwriteException('Missing required parameter: "organizationId"');
570
- }
571
- if (typeof authCode === 'undefined') {
572
- throw new AppwriteException('Missing required parameter: "authCode"');
573
- }
574
- if (typeof paymentMethodId === 'undefined') {
575
- throw new AppwriteException('Missing required parameter: "paymentMethodId"');
576
- }
577
-
578
- const apiPath = '/domains/transfers/in';
579
- const payload: Payload = {};
580
- if (typeof domain !== 'undefined') {
581
- payload['domain'] = domain;
582
- }
583
- if (typeof organizationId !== 'undefined') {
584
- payload['organizationId'] = organizationId;
585
- }
586
- if (typeof authCode !== 'undefined') {
587
- payload['authCode'] = authCode;
588
- }
589
- if (typeof autoRenewal !== 'undefined') {
590
- payload['autoRenewal'] = autoRenewal;
591
- }
592
- if (typeof paymentMethodId !== 'undefined') {
593
- payload['paymentMethodId'] = paymentMethodId;
594
- }
595
- const uri = new URL(this.client.config.endpoint + apiPath);
596
-
597
- const apiHeaders: { [header: string]: string } = {
598
- 'content-type': 'application/json',
599
- }
600
-
601
- return this.client.call(
602
- 'post',
603
- uri,
604
- apiHeaders,
605
- payload
606
- );
607
- }
608
-
609
- /**
610
- * Finalize a domain transfer-in initiated with Create Transfer In. Verifies that any required 3D Secure authentication is complete, submits the transfer with the authorization code, captures the payment, and sends a confirmation email. Returns a 402 error if authentication is still pending.
611
- *
612
- * @param {string} params.domainId - Domain ID to confirm transfer for.
613
- * @param {string} params.organizationId - Team ID that owns the domain.
614
- * @throws {AppwriteException}
615
- * @returns {Promise<Models.DomainPurchase>}
616
- */
617
- updateTransferIn(params: { domainId: string, organizationId: string }): Promise<Models.DomainPurchase>;
618
- /**
619
- * Finalize a domain transfer-in initiated with Create Transfer In. Verifies that any required 3D Secure authentication is complete, submits the transfer with the authorization code, captures the payment, and sends a confirmation email. Returns a 402 error if authentication is still pending.
620
- *
621
- * @param {string} domainId - Domain ID to confirm transfer for.
622
- * @param {string} organizationId - Team ID that owns the domain.
623
- * @throws {AppwriteException}
624
- * @returns {Promise<Models.DomainPurchase>}
625
- * @deprecated Use the object parameter style method for a better developer experience.
626
- */
627
- updateTransferIn(domainId: string, organizationId: string): Promise<Models.DomainPurchase>;
628
- updateTransferIn(
629
- paramsOrFirst: { domainId: string, organizationId: string } | string,
630
- ...rest: [(string)?]
631
- ): Promise<Models.DomainPurchase> {
632
- let params: { domainId: string, organizationId: string };
633
-
634
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
635
- params = (paramsOrFirst || {}) as { domainId: string, organizationId: string };
636
- } else {
637
- params = {
638
- domainId: paramsOrFirst as string,
639
- organizationId: rest[0] as string
640
- };
641
- }
642
-
643
- const domainId = params.domainId;
644
- const organizationId = params.organizationId;
645
-
646
- if (typeof domainId === 'undefined') {
647
- throw new AppwriteException('Missing required parameter: "domainId"');
648
- }
649
- if (typeof organizationId === 'undefined') {
650
- throw new AppwriteException('Missing required parameter: "organizationId"');
651
- }
652
-
653
- const apiPath = '/domains/transfers/in/{domainId}'.replace('{domainId}', domainId);
654
- const payload: Payload = {};
655
- if (typeof organizationId !== 'undefined') {
656
- payload['organizationId'] = organizationId;
657
- }
658
- const uri = new URL(this.client.config.endpoint + apiPath);
659
-
660
- const apiHeaders: { [header: string]: string } = {
661
- 'content-type': 'application/json',
662
- }
663
-
664
- return this.client.call(
665
- 'patch',
666
- uri,
667
- apiHeaders,
668
- payload
669
- );
670
- }
671
-
672
- /**
673
- * Initiate a domain transfer-out by generating an authorization code for the specified domain. The returned `authCode` should be provided to the gaining provider to complete the transfer. If the domain has auto-renewal enabled, it will be automatically disabled as part of this operation.
674
- *
675
- * @param {string} params.domainId - Domain unique ID.
676
- * @param {string} params.organizationId - Organization ID that this domain belongs to.
677
- * @throws {AppwriteException}
678
- * @returns {Promise<Models.DomainTransferOut>}
679
- */
680
- createTransferOut(params: { domainId: string, organizationId: string }): Promise<Models.DomainTransferOut>;
681
- /**
682
- * Initiate a domain transfer-out by generating an authorization code for the specified domain. The returned `authCode` should be provided to the gaining provider to complete the transfer. If the domain has auto-renewal enabled, it will be automatically disabled as part of this operation.
683
- *
684
- * @param {string} domainId - Domain unique ID.
685
- * @param {string} organizationId - Organization ID that this domain belongs to.
686
- * @throws {AppwriteException}
687
- * @returns {Promise<Models.DomainTransferOut>}
688
- * @deprecated Use the object parameter style method for a better developer experience.
689
- */
690
- createTransferOut(domainId: string, organizationId: string): Promise<Models.DomainTransferOut>;
691
- createTransferOut(
692
- paramsOrFirst: { domainId: string, organizationId: string } | string,
693
- ...rest: [(string)?]
694
- ): Promise<Models.DomainTransferOut> {
695
- let params: { domainId: string, organizationId: string };
696
-
697
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
698
- params = (paramsOrFirst || {}) as { domainId: string, organizationId: string };
699
- } else {
700
- params = {
701
- domainId: paramsOrFirst as string,
702
- organizationId: rest[0] as string
703
- };
704
- }
705
-
706
- const domainId = params.domainId;
707
- const organizationId = params.organizationId;
708
-
709
- if (typeof domainId === 'undefined') {
710
- throw new AppwriteException('Missing required parameter: "domainId"');
711
- }
712
- if (typeof organizationId === 'undefined') {
713
- throw new AppwriteException('Missing required parameter: "organizationId"');
714
- }
715
-
716
- const apiPath = '/domains/transfers/out';
717
- const payload: Payload = {};
718
- if (typeof domainId !== 'undefined') {
719
- payload['domainId'] = domainId;
720
- }
721
- if (typeof organizationId !== 'undefined') {
722
- payload['organizationId'] = organizationId;
723
- }
724
- const uri = new URL(this.client.config.endpoint + apiPath);
725
-
726
- const apiHeaders: { [header: string]: string } = {
727
- 'content-type': 'application/json',
728
- }
729
-
730
- return this.client.call(
731
- 'post',
732
- uri,
733
- apiHeaders,
734
- payload
735
- );
736
- }
737
-
738
- /**
739
- * Get a domain by its unique ID.
740
- *
741
- * @param {string} params.domainId - Domain unique ID.
742
- * @throws {AppwriteException}
743
- * @returns {Promise<Models.Domain>}
744
- */
745
- get(params: { domainId: string }): Promise<Models.Domain>;
746
- /**
747
- * Get a domain by its unique ID.
748
- *
749
- * @param {string} domainId - Domain unique ID.
750
- * @throws {AppwriteException}
751
- * @returns {Promise<Models.Domain>}
752
- * @deprecated Use the object parameter style method for a better developer experience.
753
- */
754
- get(domainId: string): Promise<Models.Domain>;
755
- get(
756
- paramsOrFirst: { domainId: string } | string
757
- ): Promise<Models.Domain> {
758
- let params: { domainId: string };
759
-
760
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
761
- params = (paramsOrFirst || {}) as { domainId: string };
762
- } else {
763
- params = {
764
- domainId: paramsOrFirst as string
765
- };
766
- }
767
-
768
- const domainId = params.domainId;
769
-
770
- if (typeof domainId === 'undefined') {
771
- throw new AppwriteException('Missing required parameter: "domainId"');
772
- }
773
-
774
- const apiPath = '/domains/{domainId}'.replace('{domainId}', domainId);
775
- const payload: Payload = {};
776
- const uri = new URL(this.client.config.endpoint + apiPath);
777
-
778
- const apiHeaders: { [header: string]: string } = {
779
- }
780
-
781
- return this.client.call(
782
- 'get',
783
- uri,
784
- apiHeaders,
785
- payload
786
- );
787
- }
788
-
789
- /**
790
- * Delete a domain by its unique ID. This endpoint can be used to delete a domain from your project.
791
- * Once deleted, the domain will no longer be available for use and all associated resources will be removed.
792
- *
793
- * @param {string} params.domainId - Domain unique ID.
794
- * @throws {AppwriteException}
795
- * @returns {Promise<{}>}
796
- */
797
- delete(params: { domainId: string }): Promise<{}>;
798
- /**
799
- * Delete a domain by its unique ID. This endpoint can be used to delete a domain from your project.
800
- * Once deleted, the domain will no longer be available for use and all associated resources will be removed.
801
- *
802
- * @param {string} domainId - Domain unique ID.
803
- * @throws {AppwriteException}
804
- * @returns {Promise<{}>}
805
- * @deprecated Use the object parameter style method for a better developer experience.
806
- */
807
- delete(domainId: string): Promise<{}>;
808
- delete(
809
- paramsOrFirst: { domainId: string } | string
810
- ): Promise<{}> {
811
- let params: { domainId: string };
812
-
813
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
814
- params = (paramsOrFirst || {}) as { domainId: string };
815
- } else {
816
- params = {
817
- domainId: paramsOrFirst as string
818
- };
819
- }
820
-
821
- const domainId = params.domainId;
822
-
823
- if (typeof domainId === 'undefined') {
824
- throw new AppwriteException('Missing required parameter: "domainId"');
825
- }
826
-
827
- const apiPath = '/domains/{domainId}'.replace('{domainId}', domainId);
828
- const payload: Payload = {};
829
- const uri = new URL(this.client.config.endpoint + apiPath);
830
-
831
- const apiHeaders: { [header: string]: string } = {
832
- 'content-type': 'application/json',
833
- }
834
-
835
- return this.client.call(
836
- 'delete',
837
- uri,
838
- apiHeaders,
839
- payload
840
- );
841
- }
842
-
843
- /**
844
- * Enable or disable auto-renewal for a domain.
845
- *
846
- * @param {string} params.domainId - Domain unique ID.
847
- * @param {boolean} params.autoRenewal - Whether the domain should renew automatically.
848
- * @throws {AppwriteException}
849
- * @returns {Promise<Models.Domain>}
850
- */
851
- updateAutoRenewal(params: { domainId: string, autoRenewal: boolean }): Promise<Models.Domain>;
852
- /**
853
- * Enable or disable auto-renewal for a domain.
854
- *
855
- * @param {string} domainId - Domain unique ID.
856
- * @param {boolean} autoRenewal - Whether the domain should renew automatically.
857
- * @throws {AppwriteException}
858
- * @returns {Promise<Models.Domain>}
859
- * @deprecated Use the object parameter style method for a better developer experience.
860
- */
861
- updateAutoRenewal(domainId: string, autoRenewal: boolean): Promise<Models.Domain>;
862
- updateAutoRenewal(
863
- paramsOrFirst: { domainId: string, autoRenewal: boolean } | string,
864
- ...rest: [(boolean)?]
865
- ): Promise<Models.Domain> {
866
- let params: { domainId: string, autoRenewal: boolean };
867
-
868
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
869
- params = (paramsOrFirst || {}) as { domainId: string, autoRenewal: boolean };
870
- } else {
871
- params = {
872
- domainId: paramsOrFirst as string,
873
- autoRenewal: rest[0] as boolean
874
- };
875
- }
876
-
877
- const domainId = params.domainId;
878
- const autoRenewal = params.autoRenewal;
879
-
880
- if (typeof domainId === 'undefined') {
881
- throw new AppwriteException('Missing required parameter: "domainId"');
882
- }
883
- if (typeof autoRenewal === 'undefined') {
884
- throw new AppwriteException('Missing required parameter: "autoRenewal"');
885
- }
886
-
887
- const apiPath = '/domains/{domainId}/auto-renewal'.replace('{domainId}', domainId);
888
- const payload: Payload = {};
889
- if (typeof autoRenewal !== 'undefined') {
890
- payload['autoRenewal'] = autoRenewal;
891
- }
892
- const uri = new URL(this.client.config.endpoint + apiPath);
893
-
894
- const apiHeaders: { [header: string]: string } = {
895
- 'content-type': 'application/json',
896
- }
897
-
898
- return this.client.call(
899
- 'patch',
900
- uri,
901
- apiHeaders,
902
- payload
903
- );
904
- }
905
-
906
- /**
907
- * Verify which NS records are used and update the domain accordingly. This will check the domain's
908
- * nameservers and update the domain's status based on whether the nameservers match the expected
909
- * Appwrite nameservers.
910
- *
911
- * @param {string} params.domainId - Domain unique ID.
912
- * @throws {AppwriteException}
913
- * @returns {Promise<Models.Domain>}
914
- */
915
- updateNameservers(params: { domainId: string }): Promise<Models.Domain>;
916
- /**
917
- * Verify which NS records are used and update the domain accordingly. This will check the domain's
918
- * nameservers and update the domain's status based on whether the nameservers match the expected
919
- * Appwrite nameservers.
920
- *
921
- * @param {string} domainId - Domain unique ID.
922
- * @throws {AppwriteException}
923
- * @returns {Promise<Models.Domain>}
924
- * @deprecated Use the object parameter style method for a better developer experience.
925
- */
926
- updateNameservers(domainId: string): Promise<Models.Domain>;
927
- updateNameservers(
928
- paramsOrFirst: { domainId: string } | string
929
- ): Promise<Models.Domain> {
930
- let params: { domainId: string };
931
-
932
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
933
- params = (paramsOrFirst || {}) as { domainId: string };
934
- } else {
935
- params = {
936
- domainId: paramsOrFirst as string
937
- };
938
- }
939
-
940
- const domainId = params.domainId;
941
-
942
- if (typeof domainId === 'undefined') {
943
- throw new AppwriteException('Missing required parameter: "domainId"');
944
- }
945
-
946
- const apiPath = '/domains/{domainId}/nameservers'.replace('{domainId}', domainId);
947
- const payload: Payload = {};
948
- const uri = new URL(this.client.config.endpoint + apiPath);
949
-
950
- const apiHeaders: { [header: string]: string } = {
951
- 'content-type': 'application/json',
952
- }
953
-
954
- return this.client.call(
955
- 'patch',
956
- uri,
957
- apiHeaders,
958
- payload
959
- );
960
- }
961
-
962
- /**
963
- * List Google Workspace DNS records.
964
- *
965
- * @param {string} params.domainId - Domain unique ID.
966
- * @throws {AppwriteException}
967
- * @returns {Promise<Models.DnsRecordsList>}
968
- */
969
- getPresetGoogleWorkspace(params: { domainId: string }): Promise<Models.DnsRecordsList>;
970
- /**
971
- * List Google Workspace DNS records.
972
- *
973
- * @param {string} domainId - Domain unique ID.
974
- * @throws {AppwriteException}
975
- * @returns {Promise<Models.DnsRecordsList>}
976
- * @deprecated Use the object parameter style method for a better developer experience.
977
- */
978
- getPresetGoogleWorkspace(domainId: string): Promise<Models.DnsRecordsList>;
979
- getPresetGoogleWorkspace(
980
- paramsOrFirst: { domainId: string } | string
981
- ): Promise<Models.DnsRecordsList> {
982
- let params: { domainId: string };
983
-
984
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
985
- params = (paramsOrFirst || {}) as { domainId: string };
986
- } else {
987
- params = {
988
- domainId: paramsOrFirst as string
989
- };
990
- }
991
-
992
- const domainId = params.domainId;
993
-
994
- if (typeof domainId === 'undefined') {
995
- throw new AppwriteException('Missing required parameter: "domainId"');
996
- }
997
-
998
- const apiPath = '/domains/{domainId}/presets/google-workspace'.replace('{domainId}', domainId);
999
- const payload: Payload = {};
1000
- const uri = new URL(this.client.config.endpoint + apiPath);
1001
-
1002
- const apiHeaders: { [header: string]: string } = {
1003
- }
1004
-
1005
- return this.client.call(
1006
- 'get',
1007
- uri,
1008
- apiHeaders,
1009
- payload
1010
- );
1011
- }
1012
-
1013
- /**
1014
- * Add Google Workspace DNS records to the domain. This will create the required MX records
1015
- * for Google Workspace email hosting.
1016
- *
1017
- * @param {string} params.domainId - Domain unique ID.
1018
- * @throws {AppwriteException}
1019
- * @returns {Promise<Models.DnsRecordsList>}
1020
- */
1021
- createPresetGoogleWorkspace(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1022
- /**
1023
- * Add Google Workspace DNS records to the domain. This will create the required MX records
1024
- * for Google Workspace email hosting.
1025
- *
1026
- * @param {string} domainId - Domain unique ID.
1027
- * @throws {AppwriteException}
1028
- * @returns {Promise<Models.DnsRecordsList>}
1029
- * @deprecated Use the object parameter style method for a better developer experience.
1030
- */
1031
- createPresetGoogleWorkspace(domainId: string): Promise<Models.DnsRecordsList>;
1032
- createPresetGoogleWorkspace(
1033
- paramsOrFirst: { domainId: string } | string
1034
- ): Promise<Models.DnsRecordsList> {
1035
- let params: { domainId: string };
1036
-
1037
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1038
- params = (paramsOrFirst || {}) as { domainId: string };
1039
- } else {
1040
- params = {
1041
- domainId: paramsOrFirst as string
1042
- };
1043
- }
1044
-
1045
- const domainId = params.domainId;
1046
-
1047
- if (typeof domainId === 'undefined') {
1048
- throw new AppwriteException('Missing required parameter: "domainId"');
1049
- }
1050
-
1051
- const apiPath = '/domains/{domainId}/presets/google-workspace'.replace('{domainId}', domainId);
1052
- const payload: Payload = {};
1053
- const uri = new URL(this.client.config.endpoint + apiPath);
1054
-
1055
- const apiHeaders: { [header: string]: string } = {
1056
- 'content-type': 'application/json',
1057
- }
1058
-
1059
- return this.client.call(
1060
- 'post',
1061
- uri,
1062
- apiHeaders,
1063
- payload
1064
- );
1065
- }
1066
-
1067
- /**
1068
- * List iCloud DNS records.
1069
- *
1070
- * @param {string} params.domainId - Domain unique ID.
1071
- * @throws {AppwriteException}
1072
- * @returns {Promise<Models.DnsRecordsList>}
1073
- */
1074
- getPresetICloud(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1075
- /**
1076
- * List iCloud DNS records.
1077
- *
1078
- * @param {string} domainId - Domain unique ID.
1079
- * @throws {AppwriteException}
1080
- * @returns {Promise<Models.DnsRecordsList>}
1081
- * @deprecated Use the object parameter style method for a better developer experience.
1082
- */
1083
- getPresetICloud(domainId: string): Promise<Models.DnsRecordsList>;
1084
- getPresetICloud(
1085
- paramsOrFirst: { domainId: string } | string
1086
- ): Promise<Models.DnsRecordsList> {
1087
- let params: { domainId: string };
1088
-
1089
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1090
- params = (paramsOrFirst || {}) as { domainId: string };
1091
- } else {
1092
- params = {
1093
- domainId: paramsOrFirst as string
1094
- };
1095
- }
1096
-
1097
- const domainId = params.domainId;
1098
-
1099
- if (typeof domainId === 'undefined') {
1100
- throw new AppwriteException('Missing required parameter: "domainId"');
1101
- }
1102
-
1103
- const apiPath = '/domains/{domainId}/presets/icloud'.replace('{domainId}', domainId);
1104
- const payload: Payload = {};
1105
- const uri = new URL(this.client.config.endpoint + apiPath);
1106
-
1107
- const apiHeaders: { [header: string]: string } = {
1108
- }
1109
-
1110
- return this.client.call(
1111
- 'get',
1112
- uri,
1113
- apiHeaders,
1114
- payload
1115
- );
1116
- }
1117
-
1118
- /**
1119
- * Add iCloud DNS records to the domain. This will create the required MX and SPF records
1120
- * for using iCloud email services with your domain.
1121
- *
1122
- * @param {string} params.domainId - Domain unique ID.
1123
- * @throws {AppwriteException}
1124
- * @returns {Promise<Models.DnsRecordsList>}
1125
- */
1126
- createPresetICloud(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1127
- /**
1128
- * Add iCloud DNS records to the domain. This will create the required MX and SPF records
1129
- * for using iCloud email services with your domain.
1130
- *
1131
- * @param {string} domainId - Domain unique ID.
1132
- * @throws {AppwriteException}
1133
- * @returns {Promise<Models.DnsRecordsList>}
1134
- * @deprecated Use the object parameter style method for a better developer experience.
1135
- */
1136
- createPresetICloud(domainId: string): Promise<Models.DnsRecordsList>;
1137
- createPresetICloud(
1138
- paramsOrFirst: { domainId: string } | string
1139
- ): Promise<Models.DnsRecordsList> {
1140
- let params: { domainId: string };
1141
-
1142
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1143
- params = (paramsOrFirst || {}) as { domainId: string };
1144
- } else {
1145
- params = {
1146
- domainId: paramsOrFirst as string
1147
- };
1148
- }
1149
-
1150
- const domainId = params.domainId;
1151
-
1152
- if (typeof domainId === 'undefined') {
1153
- throw new AppwriteException('Missing required parameter: "domainId"');
1154
- }
1155
-
1156
- const apiPath = '/domains/{domainId}/presets/icloud'.replace('{domainId}', domainId);
1157
- const payload: Payload = {};
1158
- const uri = new URL(this.client.config.endpoint + apiPath);
1159
-
1160
- const apiHeaders: { [header: string]: string } = {
1161
- 'content-type': 'application/json',
1162
- }
1163
-
1164
- return this.client.call(
1165
- 'post',
1166
- uri,
1167
- apiHeaders,
1168
- payload
1169
- );
1170
- }
1171
-
1172
- /**
1173
- * List Mailgun DNS records.
1174
- *
1175
- * @param {string} params.domainId - Domain unique ID.
1176
- * @throws {AppwriteException}
1177
- * @returns {Promise<Models.DnsRecordsList>}
1178
- */
1179
- getPresetMailgun(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1180
- /**
1181
- * List Mailgun DNS records.
1182
- *
1183
- * @param {string} domainId - Domain unique ID.
1184
- * @throws {AppwriteException}
1185
- * @returns {Promise<Models.DnsRecordsList>}
1186
- * @deprecated Use the object parameter style method for a better developer experience.
1187
- */
1188
- getPresetMailgun(domainId: string): Promise<Models.DnsRecordsList>;
1189
- getPresetMailgun(
1190
- paramsOrFirst: { domainId: string } | string
1191
- ): Promise<Models.DnsRecordsList> {
1192
- let params: { domainId: string };
1193
-
1194
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1195
- params = (paramsOrFirst || {}) as { domainId: string };
1196
- } else {
1197
- params = {
1198
- domainId: paramsOrFirst as string
1199
- };
1200
- }
1201
-
1202
- const domainId = params.domainId;
1203
-
1204
- if (typeof domainId === 'undefined') {
1205
- throw new AppwriteException('Missing required parameter: "domainId"');
1206
- }
1207
-
1208
- const apiPath = '/domains/{domainId}/presets/mailgun'.replace('{domainId}', domainId);
1209
- const payload: Payload = {};
1210
- const uri = new URL(this.client.config.endpoint + apiPath);
1211
-
1212
- const apiHeaders: { [header: string]: string } = {
1213
- }
1214
-
1215
- return this.client.call(
1216
- 'get',
1217
- uri,
1218
- apiHeaders,
1219
- payload
1220
- );
1221
- }
1222
-
1223
- /**
1224
- * Add Mailgun DNS records to the domain. This endpoint will create the required DNS records
1225
- * for Mailgun in the specified domain.
1226
- *
1227
- * @param {string} params.domainId - Domain unique ID.
1228
- * @throws {AppwriteException}
1229
- * @returns {Promise<Models.DnsRecordsList>}
1230
- */
1231
- createPresetMailgun(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1232
- /**
1233
- * Add Mailgun DNS records to the domain. This endpoint will create the required DNS records
1234
- * for Mailgun in the specified domain.
1235
- *
1236
- * @param {string} domainId - Domain unique ID.
1237
- * @throws {AppwriteException}
1238
- * @returns {Promise<Models.DnsRecordsList>}
1239
- * @deprecated Use the object parameter style method for a better developer experience.
1240
- */
1241
- createPresetMailgun(domainId: string): Promise<Models.DnsRecordsList>;
1242
- createPresetMailgun(
1243
- paramsOrFirst: { domainId: string } | string
1244
- ): Promise<Models.DnsRecordsList> {
1245
- let params: { domainId: string };
1246
-
1247
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1248
- params = (paramsOrFirst || {}) as { domainId: string };
1249
- } else {
1250
- params = {
1251
- domainId: paramsOrFirst as string
1252
- };
1253
- }
1254
-
1255
- const domainId = params.domainId;
1256
-
1257
- if (typeof domainId === 'undefined') {
1258
- throw new AppwriteException('Missing required parameter: "domainId"');
1259
- }
1260
-
1261
- const apiPath = '/domains/{domainId}/presets/mailgun'.replace('{domainId}', domainId);
1262
- const payload: Payload = {};
1263
- const uri = new URL(this.client.config.endpoint + apiPath);
1264
-
1265
- const apiHeaders: { [header: string]: string } = {
1266
- 'content-type': 'application/json',
1267
- }
1268
-
1269
- return this.client.call(
1270
- 'post',
1271
- uri,
1272
- apiHeaders,
1273
- payload
1274
- );
1275
- }
1276
-
1277
- /**
1278
- * List Outlook DNS records.
1279
- *
1280
- * @param {string} params.domainId - Domain unique ID.
1281
- * @throws {AppwriteException}
1282
- * @returns {Promise<Models.DnsRecordsList>}
1283
- */
1284
- getPresetOutlook(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1285
- /**
1286
- * List Outlook DNS records.
1287
- *
1288
- * @param {string} domainId - Domain unique ID.
1289
- * @throws {AppwriteException}
1290
- * @returns {Promise<Models.DnsRecordsList>}
1291
- * @deprecated Use the object parameter style method for a better developer experience.
1292
- */
1293
- getPresetOutlook(domainId: string): Promise<Models.DnsRecordsList>;
1294
- getPresetOutlook(
1295
- paramsOrFirst: { domainId: string } | string
1296
- ): Promise<Models.DnsRecordsList> {
1297
- let params: { domainId: string };
1298
-
1299
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1300
- params = (paramsOrFirst || {}) as { domainId: string };
1301
- } else {
1302
- params = {
1303
- domainId: paramsOrFirst as string
1304
- };
1305
- }
1306
-
1307
- const domainId = params.domainId;
1308
-
1309
- if (typeof domainId === 'undefined') {
1310
- throw new AppwriteException('Missing required parameter: "domainId"');
1311
- }
1312
-
1313
- const apiPath = '/domains/{domainId}/presets/outlook'.replace('{domainId}', domainId);
1314
- const payload: Payload = {};
1315
- const uri = new URL(this.client.config.endpoint + apiPath);
1316
-
1317
- const apiHeaders: { [header: string]: string } = {
1318
- }
1319
-
1320
- return this.client.call(
1321
- 'get',
1322
- uri,
1323
- apiHeaders,
1324
- payload
1325
- );
1326
- }
1327
-
1328
- /**
1329
- * Add Outlook DNS records to the domain. This will create the required MX records
1330
- * for setting up Outlook email hosting for your domain.
1331
- *
1332
- * @param {string} params.domainId - Domain unique ID.
1333
- * @throws {AppwriteException}
1334
- * @returns {Promise<Models.DnsRecordsList>}
1335
- */
1336
- createPresetOutlook(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1337
- /**
1338
- * Add Outlook DNS records to the domain. This will create the required MX records
1339
- * for setting up Outlook email hosting for your domain.
1340
- *
1341
- * @param {string} domainId - Domain unique ID.
1342
- * @throws {AppwriteException}
1343
- * @returns {Promise<Models.DnsRecordsList>}
1344
- * @deprecated Use the object parameter style method for a better developer experience.
1345
- */
1346
- createPresetOutlook(domainId: string): Promise<Models.DnsRecordsList>;
1347
- createPresetOutlook(
1348
- paramsOrFirst: { domainId: string } | string
1349
- ): Promise<Models.DnsRecordsList> {
1350
- let params: { domainId: string };
1351
-
1352
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1353
- params = (paramsOrFirst || {}) as { domainId: string };
1354
- } else {
1355
- params = {
1356
- domainId: paramsOrFirst as string
1357
- };
1358
- }
1359
-
1360
- const domainId = params.domainId;
1361
-
1362
- if (typeof domainId === 'undefined') {
1363
- throw new AppwriteException('Missing required parameter: "domainId"');
1364
- }
1365
-
1366
- const apiPath = '/domains/{domainId}/presets/outlook'.replace('{domainId}', domainId);
1367
- const payload: Payload = {};
1368
- const uri = new URL(this.client.config.endpoint + apiPath);
1369
-
1370
- const apiHeaders: { [header: string]: string } = {
1371
- 'content-type': 'application/json',
1372
- }
1373
-
1374
- return this.client.call(
1375
- 'post',
1376
- uri,
1377
- apiHeaders,
1378
- payload
1379
- );
1380
- }
1381
-
1382
- /**
1383
- * List ProtonMail DNS records.
1384
- *
1385
- * @param {string} params.domainId - Domain unique ID.
1386
- * @throws {AppwriteException}
1387
- * @returns {Promise<Models.DnsRecordsList>}
1388
- */
1389
- getPresetProtonMail(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1390
- /**
1391
- * List ProtonMail DNS records.
1392
- *
1393
- * @param {string} domainId - Domain unique ID.
1394
- * @throws {AppwriteException}
1395
- * @returns {Promise<Models.DnsRecordsList>}
1396
- * @deprecated Use the object parameter style method for a better developer experience.
1397
- */
1398
- getPresetProtonMail(domainId: string): Promise<Models.DnsRecordsList>;
1399
- getPresetProtonMail(
1400
- paramsOrFirst: { domainId: string } | string
1401
- ): Promise<Models.DnsRecordsList> {
1402
- let params: { domainId: string };
1403
-
1404
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1405
- params = (paramsOrFirst || {}) as { domainId: string };
1406
- } else {
1407
- params = {
1408
- domainId: paramsOrFirst as string
1409
- };
1410
- }
1411
-
1412
- const domainId = params.domainId;
1413
-
1414
- if (typeof domainId === 'undefined') {
1415
- throw new AppwriteException('Missing required parameter: "domainId"');
1416
- }
1417
-
1418
- const apiPath = '/domains/{domainId}/presets/proton-mail'.replace('{domainId}', domainId);
1419
- const payload: Payload = {};
1420
- const uri = new URL(this.client.config.endpoint + apiPath);
1421
-
1422
- const apiHeaders: { [header: string]: string } = {
1423
- }
1424
-
1425
- return this.client.call(
1426
- 'get',
1427
- uri,
1428
- apiHeaders,
1429
- payload
1430
- );
1431
- }
1432
-
1433
- /**
1434
- * Add ProtonMail DNS records to the domain. This will create the required MX records
1435
- * for using ProtonMail with your custom domain.
1436
- *
1437
- * @param {string} params.domainId - Domain unique ID.
1438
- * @throws {AppwriteException}
1439
- * @returns {Promise<Models.DnsRecordsList>}
1440
- */
1441
- createPresetProtonMail(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1442
- /**
1443
- * Add ProtonMail DNS records to the domain. This will create the required MX records
1444
- * for using ProtonMail with your custom domain.
1445
- *
1446
- * @param {string} domainId - Domain unique ID.
1447
- * @throws {AppwriteException}
1448
- * @returns {Promise<Models.DnsRecordsList>}
1449
- * @deprecated Use the object parameter style method for a better developer experience.
1450
- */
1451
- createPresetProtonMail(domainId: string): Promise<Models.DnsRecordsList>;
1452
- createPresetProtonMail(
1453
- paramsOrFirst: { domainId: string } | string
1454
- ): Promise<Models.DnsRecordsList> {
1455
- let params: { domainId: string };
1456
-
1457
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1458
- params = (paramsOrFirst || {}) as { domainId: string };
1459
- } else {
1460
- params = {
1461
- domainId: paramsOrFirst as string
1462
- };
1463
- }
1464
-
1465
- const domainId = params.domainId;
1466
-
1467
- if (typeof domainId === 'undefined') {
1468
- throw new AppwriteException('Missing required parameter: "domainId"');
1469
- }
1470
-
1471
- const apiPath = '/domains/{domainId}/presets/proton-mail'.replace('{domainId}', domainId);
1472
- const payload: Payload = {};
1473
- const uri = new URL(this.client.config.endpoint + apiPath);
1474
-
1475
- const apiHeaders: { [header: string]: string } = {
1476
- 'content-type': 'application/json',
1477
- }
1478
-
1479
- return this.client.call(
1480
- 'post',
1481
- uri,
1482
- apiHeaders,
1483
- payload
1484
- );
1485
- }
1486
-
1487
- /**
1488
- * List Zoho DNS records.
1489
- *
1490
- * @param {string} params.domainId - Domain unique ID.
1491
- * @throws {AppwriteException}
1492
- * @returns {Promise<Models.DnsRecordsList>}
1493
- */
1494
- getPresetZoho(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1495
- /**
1496
- * List Zoho DNS records.
1497
- *
1498
- * @param {string} domainId - Domain unique ID.
1499
- * @throws {AppwriteException}
1500
- * @returns {Promise<Models.DnsRecordsList>}
1501
- * @deprecated Use the object parameter style method for a better developer experience.
1502
- */
1503
- getPresetZoho(domainId: string): Promise<Models.DnsRecordsList>;
1504
- getPresetZoho(
1505
- paramsOrFirst: { domainId: string } | string
1506
- ): Promise<Models.DnsRecordsList> {
1507
- let params: { domainId: string };
1508
-
1509
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1510
- params = (paramsOrFirst || {}) as { domainId: string };
1511
- } else {
1512
- params = {
1513
- domainId: paramsOrFirst as string
1514
- };
1515
- }
1516
-
1517
- const domainId = params.domainId;
1518
-
1519
- if (typeof domainId === 'undefined') {
1520
- throw new AppwriteException('Missing required parameter: "domainId"');
1521
- }
1522
-
1523
- const apiPath = '/domains/{domainId}/presets/zoho'.replace('{domainId}', domainId);
1524
- const payload: Payload = {};
1525
- const uri = new URL(this.client.config.endpoint + apiPath);
1526
-
1527
- const apiHeaders: { [header: string]: string } = {
1528
- }
1529
-
1530
- return this.client.call(
1531
- 'get',
1532
- uri,
1533
- apiHeaders,
1534
- payload
1535
- );
1536
- }
1537
-
1538
- /**
1539
- * Add Zoho Mail DNS records to the domain. This will create the required MX records
1540
- * for setting up Zoho Mail on your domain.
1541
- *
1542
- * @param {string} params.domainId - Domain unique ID.
1543
- * @throws {AppwriteException}
1544
- * @returns {Promise<Models.DnsRecordsList>}
1545
- */
1546
- createPresetZoho(params: { domainId: string }): Promise<Models.DnsRecordsList>;
1547
- /**
1548
- * Add Zoho Mail DNS records to the domain. This will create the required MX records
1549
- * for setting up Zoho Mail on your domain.
1550
- *
1551
- * @param {string} domainId - Domain unique ID.
1552
- * @throws {AppwriteException}
1553
- * @returns {Promise<Models.DnsRecordsList>}
1554
- * @deprecated Use the object parameter style method for a better developer experience.
1555
- */
1556
- createPresetZoho(domainId: string): Promise<Models.DnsRecordsList>;
1557
- createPresetZoho(
1558
- paramsOrFirst: { domainId: string } | string
1559
- ): Promise<Models.DnsRecordsList> {
1560
- let params: { domainId: string };
1561
-
1562
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1563
- params = (paramsOrFirst || {}) as { domainId: string };
1564
- } else {
1565
- params = {
1566
- domainId: paramsOrFirst as string
1567
- };
1568
- }
1569
-
1570
- const domainId = params.domainId;
1571
-
1572
- if (typeof domainId === 'undefined') {
1573
- throw new AppwriteException('Missing required parameter: "domainId"');
1574
- }
1575
-
1576
- const apiPath = '/domains/{domainId}/presets/zoho'.replace('{domainId}', domainId);
1577
- const payload: Payload = {};
1578
- const uri = new URL(this.client.config.endpoint + apiPath);
1579
-
1580
- const apiHeaders: { [header: string]: string } = {
1581
- 'content-type': 'application/json',
1582
- }
1583
-
1584
- return this.client.call(
1585
- 'post',
1586
- uri,
1587
- apiHeaders,
1588
- payload
1589
- );
1590
- }
1591
-
1592
- /**
1593
- * List DNS records for a given domain. You can use this endpoint to list all the DNS records
1594
- * associated with your domain.
1595
- *
1596
- * @param {string} params.domainId - Domain unique ID.
1597
- * @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. You may filter on attributes such as type, name, value, etc. Maximum of 100 queries are allowed, each 4096 characters long.
1598
- * @throws {AppwriteException}
1599
- * @returns {Promise<Models.DnsRecordsList>}
1600
- */
1601
- listRecords(params: { domainId: string, queries?: string[] }): Promise<Models.DnsRecordsList>;
1602
- /**
1603
- * List DNS records for a given domain. You can use this endpoint to list all the DNS records
1604
- * associated with your domain.
1605
- *
1606
- * @param {string} domainId - Domain unique ID.
1607
- * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. You may filter on attributes such as type, name, value, etc. Maximum of 100 queries are allowed, each 4096 characters long.
1608
- * @throws {AppwriteException}
1609
- * @returns {Promise<Models.DnsRecordsList>}
1610
- * @deprecated Use the object parameter style method for a better developer experience.
1611
- */
1612
- listRecords(domainId: string, queries?: string[]): Promise<Models.DnsRecordsList>;
1613
- listRecords(
1614
- paramsOrFirst: { domainId: string, queries?: string[] } | string,
1615
- ...rest: [(string[])?]
1616
- ): Promise<Models.DnsRecordsList> {
1617
- let params: { domainId: string, queries?: string[] };
1618
-
1619
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1620
- params = (paramsOrFirst || {}) as { domainId: string, queries?: string[] };
1621
- } else {
1622
- params = {
1623
- domainId: paramsOrFirst as string,
1624
- queries: rest[0] as string[]
1625
- };
1626
- }
1627
-
1628
- const domainId = params.domainId;
1629
- const queries = params.queries;
1630
-
1631
- if (typeof domainId === 'undefined') {
1632
- throw new AppwriteException('Missing required parameter: "domainId"');
1633
- }
1634
-
1635
- const apiPath = '/domains/{domainId}/records'.replace('{domainId}', domainId);
1636
- const payload: Payload = {};
1637
- if (typeof queries !== 'undefined') {
1638
- payload['queries'] = queries;
1639
- }
1640
- const uri = new URL(this.client.config.endpoint + apiPath);
1641
-
1642
- const apiHeaders: { [header: string]: string } = {
1643
- }
1644
-
1645
- return this.client.call(
1646
- 'get',
1647
- uri,
1648
- apiHeaders,
1649
- payload
1650
- );
1651
- }
1652
-
1653
- /**
1654
- * Create a new A record for the given domain. A records are used to point a domain name
1655
- * to an IPv4 address. The record value should be a valid IPv4 address.
1656
- *
1657
- * @param {string} params.domainId - Domain unique ID.
1658
- * @param {string} params.name - Record name (subdomain).
1659
- * @param {string} params.value - IPv4 address for this A record.
1660
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
1661
- * @param {string} params.comment - A comment explaining what this record is for.
1662
- * @throws {AppwriteException}
1663
- * @returns {Promise<Models.DnsRecord>}
1664
- */
1665
- createRecordA(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
1666
- /**
1667
- * Create a new A record for the given domain. A records are used to point a domain name
1668
- * to an IPv4 address. The record value should be a valid IPv4 address.
1669
- *
1670
- * @param {string} domainId - Domain unique ID.
1671
- * @param {string} name - Record name (subdomain).
1672
- * @param {string} value - IPv4 address for this A record.
1673
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
1674
- * @param {string} comment - A comment explaining what this record is for.
1675
- * @throws {AppwriteException}
1676
- * @returns {Promise<Models.DnsRecord>}
1677
- * @deprecated Use the object parameter style method for a better developer experience.
1678
- */
1679
- createRecordA(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
1680
- createRecordA(
1681
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
1682
- ...rest: [(string)?, (string)?, (number)?, (string)?]
1683
- ): Promise<Models.DnsRecord> {
1684
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
1685
-
1686
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1687
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
1688
- } else {
1689
- params = {
1690
- domainId: paramsOrFirst as string,
1691
- name: rest[0] as string,
1692
- value: rest[1] as string,
1693
- ttl: rest[2] as number,
1694
- comment: rest[3] as string
1695
- };
1696
- }
1697
-
1698
- const domainId = params.domainId;
1699
- const name = params.name;
1700
- const value = params.value;
1701
- const ttl = params.ttl;
1702
- const comment = params.comment;
1703
-
1704
- if (typeof domainId === 'undefined') {
1705
- throw new AppwriteException('Missing required parameter: "domainId"');
1706
- }
1707
- if (typeof name === 'undefined') {
1708
- throw new AppwriteException('Missing required parameter: "name"');
1709
- }
1710
- if (typeof value === 'undefined') {
1711
- throw new AppwriteException('Missing required parameter: "value"');
1712
- }
1713
- if (typeof ttl === 'undefined') {
1714
- throw new AppwriteException('Missing required parameter: "ttl"');
1715
- }
1716
-
1717
- const apiPath = '/domains/{domainId}/records/a'.replace('{domainId}', domainId);
1718
- const payload: Payload = {};
1719
- if (typeof name !== 'undefined') {
1720
- payload['name'] = name;
1721
- }
1722
- if (typeof value !== 'undefined') {
1723
- payload['value'] = value;
1724
- }
1725
- if (typeof ttl !== 'undefined') {
1726
- payload['ttl'] = ttl;
1727
- }
1728
- if (typeof comment !== 'undefined') {
1729
- payload['comment'] = comment;
1730
- }
1731
- const uri = new URL(this.client.config.endpoint + apiPath);
1732
-
1733
- const apiHeaders: { [header: string]: string } = {
1734
- 'content-type': 'application/json',
1735
- }
1736
-
1737
- return this.client.call(
1738
- 'post',
1739
- uri,
1740
- apiHeaders,
1741
- payload
1742
- );
1743
- }
1744
-
1745
- /**
1746
- * Update an existing A record for the given domain. This endpoint allows you to modify
1747
- * the properties of an A record including its name (subdomain), IPv4 address, TTL,
1748
- * and optional comment.
1749
- *
1750
- * @param {string} params.domainId - Domain unique ID.
1751
- * @param {string} params.recordId - DNS record unique ID.
1752
- * @param {string} params.name - Record name (subdomain).
1753
- * @param {string} params.value - IPv4 address for this A record.
1754
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
1755
- * @param {string} params.comment - A comment explaining what this record is for.
1756
- * @throws {AppwriteException}
1757
- * @returns {Promise<Models.DnsRecord>}
1758
- */
1759
- updateRecordA(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
1760
- /**
1761
- * Update an existing A record for the given domain. This endpoint allows you to modify
1762
- * the properties of an A record including its name (subdomain), IPv4 address, TTL,
1763
- * and optional comment.
1764
- *
1765
- * @param {string} domainId - Domain unique ID.
1766
- * @param {string} recordId - DNS record unique ID.
1767
- * @param {string} name - Record name (subdomain).
1768
- * @param {string} value - IPv4 address for this A record.
1769
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
1770
- * @param {string} comment - A comment explaining what this record is for.
1771
- * @throws {AppwriteException}
1772
- * @returns {Promise<Models.DnsRecord>}
1773
- * @deprecated Use the object parameter style method for a better developer experience.
1774
- */
1775
- updateRecordA(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
1776
- updateRecordA(
1777
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
1778
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
1779
- ): Promise<Models.DnsRecord> {
1780
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
1781
-
1782
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1783
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
1784
- } else {
1785
- params = {
1786
- domainId: paramsOrFirst as string,
1787
- recordId: rest[0] as string,
1788
- name: rest[1] as string,
1789
- value: rest[2] as string,
1790
- ttl: rest[3] as number,
1791
- comment: rest[4] as string
1792
- };
1793
- }
1794
-
1795
- const domainId = params.domainId;
1796
- const recordId = params.recordId;
1797
- const name = params.name;
1798
- const value = params.value;
1799
- const ttl = params.ttl;
1800
- const comment = params.comment;
1801
-
1802
- if (typeof domainId === 'undefined') {
1803
- throw new AppwriteException('Missing required parameter: "domainId"');
1804
- }
1805
- if (typeof recordId === 'undefined') {
1806
- throw new AppwriteException('Missing required parameter: "recordId"');
1807
- }
1808
- if (typeof name === 'undefined') {
1809
- throw new AppwriteException('Missing required parameter: "name"');
1810
- }
1811
- if (typeof value === 'undefined') {
1812
- throw new AppwriteException('Missing required parameter: "value"');
1813
- }
1814
- if (typeof ttl === 'undefined') {
1815
- throw new AppwriteException('Missing required parameter: "ttl"');
1816
- }
1817
-
1818
- const apiPath = '/domains/{domainId}/records/a/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
1819
- const payload: Payload = {};
1820
- if (typeof name !== 'undefined') {
1821
- payload['name'] = name;
1822
- }
1823
- if (typeof value !== 'undefined') {
1824
- payload['value'] = value;
1825
- }
1826
- if (typeof ttl !== 'undefined') {
1827
- payload['ttl'] = ttl;
1828
- }
1829
- if (typeof comment !== 'undefined') {
1830
- payload['comment'] = comment;
1831
- }
1832
- const uri = new URL(this.client.config.endpoint + apiPath);
1833
-
1834
- const apiHeaders: { [header: string]: string } = {
1835
- 'content-type': 'application/json',
1836
- }
1837
-
1838
- return this.client.call(
1839
- 'put',
1840
- uri,
1841
- apiHeaders,
1842
- payload
1843
- );
1844
- }
1845
-
1846
- /**
1847
- * Create a new AAAA record for the given domain. This endpoint allows you to add a new IPv6 DNS record
1848
- * to your domain. The record will be used to point a hostname to an IPv6 address.
1849
- *
1850
- * @param {string} params.domainId - Domain unique ID.
1851
- * @param {string} params.name - Record name (subdomain).
1852
- * @param {string} params.value - IPv6 address for this AAAA record.
1853
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
1854
- * @param {string} params.comment - A comment explaining what this record is for.
1855
- * @throws {AppwriteException}
1856
- * @returns {Promise<Models.DnsRecord>}
1857
- */
1858
- createRecordAAAA(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
1859
- /**
1860
- * Create a new AAAA record for the given domain. This endpoint allows you to add a new IPv6 DNS record
1861
- * to your domain. The record will be used to point a hostname to an IPv6 address.
1862
- *
1863
- * @param {string} domainId - Domain unique ID.
1864
- * @param {string} name - Record name (subdomain).
1865
- * @param {string} value - IPv6 address for this AAAA record.
1866
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
1867
- * @param {string} comment - A comment explaining what this record is for.
1868
- * @throws {AppwriteException}
1869
- * @returns {Promise<Models.DnsRecord>}
1870
- * @deprecated Use the object parameter style method for a better developer experience.
1871
- */
1872
- createRecordAAAA(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
1873
- createRecordAAAA(
1874
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
1875
- ...rest: [(string)?, (string)?, (number)?, (string)?]
1876
- ): Promise<Models.DnsRecord> {
1877
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
1878
-
1879
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1880
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
1881
- } else {
1882
- params = {
1883
- domainId: paramsOrFirst as string,
1884
- name: rest[0] as string,
1885
- value: rest[1] as string,
1886
- ttl: rest[2] as number,
1887
- comment: rest[3] as string
1888
- };
1889
- }
1890
-
1891
- const domainId = params.domainId;
1892
- const name = params.name;
1893
- const value = params.value;
1894
- const ttl = params.ttl;
1895
- const comment = params.comment;
1896
-
1897
- if (typeof domainId === 'undefined') {
1898
- throw new AppwriteException('Missing required parameter: "domainId"');
1899
- }
1900
- if (typeof name === 'undefined') {
1901
- throw new AppwriteException('Missing required parameter: "name"');
1902
- }
1903
- if (typeof value === 'undefined') {
1904
- throw new AppwriteException('Missing required parameter: "value"');
1905
- }
1906
- if (typeof ttl === 'undefined') {
1907
- throw new AppwriteException('Missing required parameter: "ttl"');
1908
- }
1909
-
1910
- const apiPath = '/domains/{domainId}/records/aaaa'.replace('{domainId}', domainId);
1911
- const payload: Payload = {};
1912
- if (typeof name !== 'undefined') {
1913
- payload['name'] = name;
1914
- }
1915
- if (typeof value !== 'undefined') {
1916
- payload['value'] = value;
1917
- }
1918
- if (typeof ttl !== 'undefined') {
1919
- payload['ttl'] = ttl;
1920
- }
1921
- if (typeof comment !== 'undefined') {
1922
- payload['comment'] = comment;
1923
- }
1924
- const uri = new URL(this.client.config.endpoint + apiPath);
1925
-
1926
- const apiHeaders: { [header: string]: string } = {
1927
- 'content-type': 'application/json',
1928
- }
1929
-
1930
- return this.client.call(
1931
- 'post',
1932
- uri,
1933
- apiHeaders,
1934
- payload
1935
- );
1936
- }
1937
-
1938
- /**
1939
- * Update an existing AAAA record for the given domain. This endpoint allows you to modify
1940
- * the properties of an existing AAAA record, including its name (subdomain), IPv6 address,
1941
- * TTL, and optional comment.
1942
- *
1943
- * @param {string} params.domainId - Domain unique ID.
1944
- * @param {string} params.recordId - DNS record unique ID.
1945
- * @param {string} params.name - Record name (subdomain).
1946
- * @param {string} params.value - IPv6 address for this AAAA record.
1947
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
1948
- * @param {string} params.comment - A comment for this record.
1949
- * @throws {AppwriteException}
1950
- * @returns {Promise<Models.DnsRecord>}
1951
- */
1952
- updateRecordAAAA(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
1953
- /**
1954
- * Update an existing AAAA record for the given domain. This endpoint allows you to modify
1955
- * the properties of an existing AAAA record, including its name (subdomain), IPv6 address,
1956
- * TTL, and optional comment.
1957
- *
1958
- * @param {string} domainId - Domain unique ID.
1959
- * @param {string} recordId - DNS record unique ID.
1960
- * @param {string} name - Record name (subdomain).
1961
- * @param {string} value - IPv6 address for this AAAA record.
1962
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
1963
- * @param {string} comment - A comment for this record.
1964
- * @throws {AppwriteException}
1965
- * @returns {Promise<Models.DnsRecord>}
1966
- * @deprecated Use the object parameter style method for a better developer experience.
1967
- */
1968
- updateRecordAAAA(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
1969
- updateRecordAAAA(
1970
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
1971
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
1972
- ): Promise<Models.DnsRecord> {
1973
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
1974
-
1975
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
1976
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
1977
- } else {
1978
- params = {
1979
- domainId: paramsOrFirst as string,
1980
- recordId: rest[0] as string,
1981
- name: rest[1] as string,
1982
- value: rest[2] as string,
1983
- ttl: rest[3] as number,
1984
- comment: rest[4] as string
1985
- };
1986
- }
1987
-
1988
- const domainId = params.domainId;
1989
- const recordId = params.recordId;
1990
- const name = params.name;
1991
- const value = params.value;
1992
- const ttl = params.ttl;
1993
- const comment = params.comment;
1994
-
1995
- if (typeof domainId === 'undefined') {
1996
- throw new AppwriteException('Missing required parameter: "domainId"');
1997
- }
1998
- if (typeof recordId === 'undefined') {
1999
- throw new AppwriteException('Missing required parameter: "recordId"');
2000
- }
2001
- if (typeof name === 'undefined') {
2002
- throw new AppwriteException('Missing required parameter: "name"');
2003
- }
2004
- if (typeof value === 'undefined') {
2005
- throw new AppwriteException('Missing required parameter: "value"');
2006
- }
2007
- if (typeof ttl === 'undefined') {
2008
- throw new AppwriteException('Missing required parameter: "ttl"');
2009
- }
2010
-
2011
- const apiPath = '/domains/{domainId}/records/aaaa/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
2012
- const payload: Payload = {};
2013
- if (typeof name !== 'undefined') {
2014
- payload['name'] = name;
2015
- }
2016
- if (typeof value !== 'undefined') {
2017
- payload['value'] = value;
2018
- }
2019
- if (typeof ttl !== 'undefined') {
2020
- payload['ttl'] = ttl;
2021
- }
2022
- if (typeof comment !== 'undefined') {
2023
- payload['comment'] = comment;
2024
- }
2025
- const uri = new URL(this.client.config.endpoint + apiPath);
2026
-
2027
- const apiHeaders: { [header: string]: string } = {
2028
- 'content-type': 'application/json',
2029
- }
2030
-
2031
- return this.client.call(
2032
- 'put',
2033
- uri,
2034
- apiHeaders,
2035
- payload
2036
- );
2037
- }
2038
-
2039
- /**
2040
- * Create a new ALIAS record for the given domain. This record type can be used to point your domain
2041
- * to another domain name that will serve as an alias. This is particularly useful when you want to
2042
- * map your domain to a target domain that may change its IP address.
2043
- *
2044
- * @param {string} params.domainId - Domain unique ID.
2045
- * @param {string} params.name - Record name.
2046
- * @param {string} params.value - Target domain for this ALIAS record.
2047
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2048
- * @param {string} params.comment - A comment for this record.
2049
- * @throws {AppwriteException}
2050
- * @returns {Promise<Models.DnsRecord>}
2051
- */
2052
- createRecordAlias(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2053
- /**
2054
- * Create a new ALIAS record for the given domain. This record type can be used to point your domain
2055
- * to another domain name that will serve as an alias. This is particularly useful when you want to
2056
- * map your domain to a target domain that may change its IP address.
2057
- *
2058
- * @param {string} domainId - Domain unique ID.
2059
- * @param {string} name - Record name.
2060
- * @param {string} value - Target domain for this ALIAS record.
2061
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2062
- * @param {string} comment - A comment for this record.
2063
- * @throws {AppwriteException}
2064
- * @returns {Promise<Models.DnsRecord>}
2065
- * @deprecated Use the object parameter style method for a better developer experience.
2066
- */
2067
- createRecordAlias(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2068
- createRecordAlias(
2069
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
2070
- ...rest: [(string)?, (string)?, (number)?, (string)?]
2071
- ): Promise<Models.DnsRecord> {
2072
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
2073
-
2074
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2075
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
2076
- } else {
2077
- params = {
2078
- domainId: paramsOrFirst as string,
2079
- name: rest[0] as string,
2080
- value: rest[1] as string,
2081
- ttl: rest[2] as number,
2082
- comment: rest[3] as string
2083
- };
2084
- }
2085
-
2086
- const domainId = params.domainId;
2087
- const name = params.name;
2088
- const value = params.value;
2089
- const ttl = params.ttl;
2090
- const comment = params.comment;
2091
-
2092
- if (typeof domainId === 'undefined') {
2093
- throw new AppwriteException('Missing required parameter: "domainId"');
2094
- }
2095
- if (typeof name === 'undefined') {
2096
- throw new AppwriteException('Missing required parameter: "name"');
2097
- }
2098
- if (typeof value === 'undefined') {
2099
- throw new AppwriteException('Missing required parameter: "value"');
2100
- }
2101
- if (typeof ttl === 'undefined') {
2102
- throw new AppwriteException('Missing required parameter: "ttl"');
2103
- }
2104
-
2105
- const apiPath = '/domains/{domainId}/records/alias'.replace('{domainId}', domainId);
2106
- const payload: Payload = {};
2107
- if (typeof name !== 'undefined') {
2108
- payload['name'] = name;
2109
- }
2110
- if (typeof value !== 'undefined') {
2111
- payload['value'] = value;
2112
- }
2113
- if (typeof ttl !== 'undefined') {
2114
- payload['ttl'] = ttl;
2115
- }
2116
- if (typeof comment !== 'undefined') {
2117
- payload['comment'] = comment;
2118
- }
2119
- const uri = new URL(this.client.config.endpoint + apiPath);
2120
-
2121
- const apiHeaders: { [header: string]: string } = {
2122
- 'content-type': 'application/json',
2123
- }
2124
-
2125
- return this.client.call(
2126
- 'post',
2127
- uri,
2128
- apiHeaders,
2129
- payload
2130
- );
2131
- }
2132
-
2133
- /**
2134
- * Update an existing ALIAS record for the specified domain. This endpoint allows you to modify
2135
- * the properties of an existing ALIAS record including its name, target domain, TTL, and comment.
2136
- *
2137
- * The ALIAS record type is similar to a CNAME record but can be used at the zone apex (root domain).
2138
- * It provides a way to map one domain name to another.
2139
- *
2140
- * @param {string} params.domainId - Domain unique ID.
2141
- * @param {string} params.recordId - DNS record unique ID.
2142
- * @param {string} params.name - Record name.
2143
- * @param {string} params.value - Target domain for this ALIAS record.
2144
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2145
- * @param {string} params.comment - A comment for this record.
2146
- * @throws {AppwriteException}
2147
- * @returns {Promise<Models.DnsRecord>}
2148
- */
2149
- updateRecordAlias(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2150
- /**
2151
- * Update an existing ALIAS record for the specified domain. This endpoint allows you to modify
2152
- * the properties of an existing ALIAS record including its name, target domain, TTL, and comment.
2153
- *
2154
- * The ALIAS record type is similar to a CNAME record but can be used at the zone apex (root domain).
2155
- * It provides a way to map one domain name to another.
2156
- *
2157
- * @param {string} domainId - Domain unique ID.
2158
- * @param {string} recordId - DNS record unique ID.
2159
- * @param {string} name - Record name.
2160
- * @param {string} value - Target domain for this ALIAS record.
2161
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2162
- * @param {string} comment - A comment for this record.
2163
- * @throws {AppwriteException}
2164
- * @returns {Promise<Models.DnsRecord>}
2165
- * @deprecated Use the object parameter style method for a better developer experience.
2166
- */
2167
- updateRecordAlias(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2168
- updateRecordAlias(
2169
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
2170
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
2171
- ): Promise<Models.DnsRecord> {
2172
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2173
-
2174
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2175
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2176
- } else {
2177
- params = {
2178
- domainId: paramsOrFirst as string,
2179
- recordId: rest[0] as string,
2180
- name: rest[1] as string,
2181
- value: rest[2] as string,
2182
- ttl: rest[3] as number,
2183
- comment: rest[4] as string
2184
- };
2185
- }
2186
-
2187
- const domainId = params.domainId;
2188
- const recordId = params.recordId;
2189
- const name = params.name;
2190
- const value = params.value;
2191
- const ttl = params.ttl;
2192
- const comment = params.comment;
2193
-
2194
- if (typeof domainId === 'undefined') {
2195
- throw new AppwriteException('Missing required parameter: "domainId"');
2196
- }
2197
- if (typeof recordId === 'undefined') {
2198
- throw new AppwriteException('Missing required parameter: "recordId"');
2199
- }
2200
- if (typeof name === 'undefined') {
2201
- throw new AppwriteException('Missing required parameter: "name"');
2202
- }
2203
- if (typeof value === 'undefined') {
2204
- throw new AppwriteException('Missing required parameter: "value"');
2205
- }
2206
- if (typeof ttl === 'undefined') {
2207
- throw new AppwriteException('Missing required parameter: "ttl"');
2208
- }
2209
-
2210
- const apiPath = '/domains/{domainId}/records/alias/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
2211
- const payload: Payload = {};
2212
- if (typeof name !== 'undefined') {
2213
- payload['name'] = name;
2214
- }
2215
- if (typeof value !== 'undefined') {
2216
- payload['value'] = value;
2217
- }
2218
- if (typeof ttl !== 'undefined') {
2219
- payload['ttl'] = ttl;
2220
- }
2221
- if (typeof comment !== 'undefined') {
2222
- payload['comment'] = comment;
2223
- }
2224
- const uri = new URL(this.client.config.endpoint + apiPath);
2225
-
2226
- const apiHeaders: { [header: string]: string } = {
2227
- 'content-type': 'application/json',
2228
- }
2229
-
2230
- return this.client.call(
2231
- 'put',
2232
- uri,
2233
- apiHeaders,
2234
- payload
2235
- );
2236
- }
2237
-
2238
- /**
2239
- * Create a new CAA record for the given domain. CAA records are used to specify which
2240
- * Certificate Authorities (CAs) are allowed to issue SSL/TLS certificates for your domain.
2241
- *
2242
- * @param {string} params.domainId - Domain unique ID.
2243
- * @param {string} params.name - Record name.
2244
- * @param {string} params.value - CAA value (e.g. issuer domain).
2245
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2246
- * @param {string} params.comment - A comment for this record.
2247
- * @throws {AppwriteException}
2248
- * @returns {Promise<Models.DnsRecord>}
2249
- */
2250
- createRecordCAA(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2251
- /**
2252
- * Create a new CAA record for the given domain. CAA records are used to specify which
2253
- * Certificate Authorities (CAs) are allowed to issue SSL/TLS certificates for your domain.
2254
- *
2255
- * @param {string} domainId - Domain unique ID.
2256
- * @param {string} name - Record name.
2257
- * @param {string} value - CAA value (e.g. issuer domain).
2258
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2259
- * @param {string} comment - A comment for this record.
2260
- * @throws {AppwriteException}
2261
- * @returns {Promise<Models.DnsRecord>}
2262
- * @deprecated Use the object parameter style method for a better developer experience.
2263
- */
2264
- createRecordCAA(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2265
- createRecordCAA(
2266
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
2267
- ...rest: [(string)?, (string)?, (number)?, (string)?]
2268
- ): Promise<Models.DnsRecord> {
2269
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
2270
-
2271
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2272
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
2273
- } else {
2274
- params = {
2275
- domainId: paramsOrFirst as string,
2276
- name: rest[0] as string,
2277
- value: rest[1] as string,
2278
- ttl: rest[2] as number,
2279
- comment: rest[3] as string
2280
- };
2281
- }
2282
-
2283
- const domainId = params.domainId;
2284
- const name = params.name;
2285
- const value = params.value;
2286
- const ttl = params.ttl;
2287
- const comment = params.comment;
2288
-
2289
- if (typeof domainId === 'undefined') {
2290
- throw new AppwriteException('Missing required parameter: "domainId"');
2291
- }
2292
- if (typeof name === 'undefined') {
2293
- throw new AppwriteException('Missing required parameter: "name"');
2294
- }
2295
- if (typeof value === 'undefined') {
2296
- throw new AppwriteException('Missing required parameter: "value"');
2297
- }
2298
- if (typeof ttl === 'undefined') {
2299
- throw new AppwriteException('Missing required parameter: "ttl"');
2300
- }
2301
-
2302
- const apiPath = '/domains/{domainId}/records/caa'.replace('{domainId}', domainId);
2303
- const payload: Payload = {};
2304
- if (typeof name !== 'undefined') {
2305
- payload['name'] = name;
2306
- }
2307
- if (typeof value !== 'undefined') {
2308
- payload['value'] = value;
2309
- }
2310
- if (typeof ttl !== 'undefined') {
2311
- payload['ttl'] = ttl;
2312
- }
2313
- if (typeof comment !== 'undefined') {
2314
- payload['comment'] = comment;
2315
- }
2316
- const uri = new URL(this.client.config.endpoint + apiPath);
2317
-
2318
- const apiHeaders: { [header: string]: string } = {
2319
- 'content-type': 'application/json',
2320
- }
2321
-
2322
- return this.client.call(
2323
- 'post',
2324
- uri,
2325
- apiHeaders,
2326
- payload
2327
- );
2328
- }
2329
-
2330
- /**
2331
- * Update an existing CAA record for the given domain. A CAA (Certification Authority Authorization)
2332
- * record is used to specify which certificate authorities (CAs) are authorized to issue certificates
2333
- * for a domain.
2334
- *
2335
- * @param {string} params.domainId - Domain unique ID.
2336
- * @param {string} params.recordId - DNS record unique ID.
2337
- * @param {string} params.name - Record name.
2338
- * @param {string} params.value - CAA value (e.g. issuer domain).
2339
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2340
- * @param {string} params.comment - A comment for this record.
2341
- * @throws {AppwriteException}
2342
- * @returns {Promise<Models.DnsRecord>}
2343
- */
2344
- updateRecordCAA(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2345
- /**
2346
- * Update an existing CAA record for the given domain. A CAA (Certification Authority Authorization)
2347
- * record is used to specify which certificate authorities (CAs) are authorized to issue certificates
2348
- * for a domain.
2349
- *
2350
- * @param {string} domainId - Domain unique ID.
2351
- * @param {string} recordId - DNS record unique ID.
2352
- * @param {string} name - Record name.
2353
- * @param {string} value - CAA value (e.g. issuer domain).
2354
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2355
- * @param {string} comment - A comment for this record.
2356
- * @throws {AppwriteException}
2357
- * @returns {Promise<Models.DnsRecord>}
2358
- * @deprecated Use the object parameter style method for a better developer experience.
2359
- */
2360
- updateRecordCAA(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2361
- updateRecordCAA(
2362
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
2363
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
2364
- ): Promise<Models.DnsRecord> {
2365
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2366
-
2367
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2368
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2369
- } else {
2370
- params = {
2371
- domainId: paramsOrFirst as string,
2372
- recordId: rest[0] as string,
2373
- name: rest[1] as string,
2374
- value: rest[2] as string,
2375
- ttl: rest[3] as number,
2376
- comment: rest[4] as string
2377
- };
2378
- }
2379
-
2380
- const domainId = params.domainId;
2381
- const recordId = params.recordId;
2382
- const name = params.name;
2383
- const value = params.value;
2384
- const ttl = params.ttl;
2385
- const comment = params.comment;
2386
-
2387
- if (typeof domainId === 'undefined') {
2388
- throw new AppwriteException('Missing required parameter: "domainId"');
2389
- }
2390
- if (typeof recordId === 'undefined') {
2391
- throw new AppwriteException('Missing required parameter: "recordId"');
2392
- }
2393
- if (typeof name === 'undefined') {
2394
- throw new AppwriteException('Missing required parameter: "name"');
2395
- }
2396
- if (typeof value === 'undefined') {
2397
- throw new AppwriteException('Missing required parameter: "value"');
2398
- }
2399
- if (typeof ttl === 'undefined') {
2400
- throw new AppwriteException('Missing required parameter: "ttl"');
2401
- }
2402
-
2403
- const apiPath = '/domains/{domainId}/records/caa/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
2404
- const payload: Payload = {};
2405
- if (typeof name !== 'undefined') {
2406
- payload['name'] = name;
2407
- }
2408
- if (typeof value !== 'undefined') {
2409
- payload['value'] = value;
2410
- }
2411
- if (typeof ttl !== 'undefined') {
2412
- payload['ttl'] = ttl;
2413
- }
2414
- if (typeof comment !== 'undefined') {
2415
- payload['comment'] = comment;
2416
- }
2417
- const uri = new URL(this.client.config.endpoint + apiPath);
2418
-
2419
- const apiHeaders: { [header: string]: string } = {
2420
- 'content-type': 'application/json',
2421
- }
2422
-
2423
- return this.client.call(
2424
- 'put',
2425
- uri,
2426
- apiHeaders,
2427
- payload
2428
- );
2429
- }
2430
-
2431
- /**
2432
- * Create a new CNAME record for the given domain.
2433
- *
2434
- * A CNAME record maps a subdomain to another domain name, allowing you to create aliases
2435
- * for your domain. For example, you can create a CNAME record to point 'blog.example.com'
2436
- * to 'example.wordpress.com'.
2437
- *
2438
- * @param {string} params.domainId - Domain unique ID.
2439
- * @param {string} params.name - Record name (subdomain).
2440
- * @param {string} params.value - Canonical target for this CNAME record.
2441
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2442
- * @param {string} params.comment - A comment for this record.
2443
- * @throws {AppwriteException}
2444
- * @returns {Promise<Models.DnsRecord>}
2445
- */
2446
- createRecordCNAME(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2447
- /**
2448
- * Create a new CNAME record for the given domain.
2449
- *
2450
- * A CNAME record maps a subdomain to another domain name, allowing you to create aliases
2451
- * for your domain. For example, you can create a CNAME record to point 'blog.example.com'
2452
- * to 'example.wordpress.com'.
2453
- *
2454
- * @param {string} domainId - Domain unique ID.
2455
- * @param {string} name - Record name (subdomain).
2456
- * @param {string} value - Canonical target for this CNAME record.
2457
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2458
- * @param {string} comment - A comment for this record.
2459
- * @throws {AppwriteException}
2460
- * @returns {Promise<Models.DnsRecord>}
2461
- * @deprecated Use the object parameter style method for a better developer experience.
2462
- */
2463
- createRecordCNAME(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2464
- createRecordCNAME(
2465
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
2466
- ...rest: [(string)?, (string)?, (number)?, (string)?]
2467
- ): Promise<Models.DnsRecord> {
2468
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
2469
-
2470
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2471
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
2472
- } else {
2473
- params = {
2474
- domainId: paramsOrFirst as string,
2475
- name: rest[0] as string,
2476
- value: rest[1] as string,
2477
- ttl: rest[2] as number,
2478
- comment: rest[3] as string
2479
- };
2480
- }
2481
-
2482
- const domainId = params.domainId;
2483
- const name = params.name;
2484
- const value = params.value;
2485
- const ttl = params.ttl;
2486
- const comment = params.comment;
2487
-
2488
- if (typeof domainId === 'undefined') {
2489
- throw new AppwriteException('Missing required parameter: "domainId"');
2490
- }
2491
- if (typeof name === 'undefined') {
2492
- throw new AppwriteException('Missing required parameter: "name"');
2493
- }
2494
- if (typeof value === 'undefined') {
2495
- throw new AppwriteException('Missing required parameter: "value"');
2496
- }
2497
- if (typeof ttl === 'undefined') {
2498
- throw new AppwriteException('Missing required parameter: "ttl"');
2499
- }
2500
-
2501
- const apiPath = '/domains/{domainId}/records/cname'.replace('{domainId}', domainId);
2502
- const payload: Payload = {};
2503
- if (typeof name !== 'undefined') {
2504
- payload['name'] = name;
2505
- }
2506
- if (typeof value !== 'undefined') {
2507
- payload['value'] = value;
2508
- }
2509
- if (typeof ttl !== 'undefined') {
2510
- payload['ttl'] = ttl;
2511
- }
2512
- if (typeof comment !== 'undefined') {
2513
- payload['comment'] = comment;
2514
- }
2515
- const uri = new URL(this.client.config.endpoint + apiPath);
2516
-
2517
- const apiHeaders: { [header: string]: string } = {
2518
- 'content-type': 'application/json',
2519
- }
2520
-
2521
- return this.client.call(
2522
- 'post',
2523
- uri,
2524
- apiHeaders,
2525
- payload
2526
- );
2527
- }
2528
-
2529
- /**
2530
- * Update an existing CNAME record for the given domain.
2531
- *
2532
- * @param {string} params.domainId - Domain unique ID.
2533
- * @param {string} params.recordId - DNS record unique ID.
2534
- * @param {string} params.name - Record name (subdomain).
2535
- * @param {string} params.value - Canonical target for this CNAME record.
2536
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2537
- * @param {string} params.comment - A comment for this record.
2538
- * @throws {AppwriteException}
2539
- * @returns {Promise<Models.DnsRecord>}
2540
- */
2541
- updateRecordCNAME(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2542
- /**
2543
- * Update an existing CNAME record for the given domain.
2544
- *
2545
- * @param {string} domainId - Domain unique ID.
2546
- * @param {string} recordId - DNS record unique ID.
2547
- * @param {string} name - Record name (subdomain).
2548
- * @param {string} value - Canonical target for this CNAME record.
2549
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2550
- * @param {string} comment - A comment for this record.
2551
- * @throws {AppwriteException}
2552
- * @returns {Promise<Models.DnsRecord>}
2553
- * @deprecated Use the object parameter style method for a better developer experience.
2554
- */
2555
- updateRecordCNAME(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2556
- updateRecordCNAME(
2557
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
2558
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
2559
- ): Promise<Models.DnsRecord> {
2560
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2561
-
2562
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2563
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2564
- } else {
2565
- params = {
2566
- domainId: paramsOrFirst as string,
2567
- recordId: rest[0] as string,
2568
- name: rest[1] as string,
2569
- value: rest[2] as string,
2570
- ttl: rest[3] as number,
2571
- comment: rest[4] as string
2572
- };
2573
- }
2574
-
2575
- const domainId = params.domainId;
2576
- const recordId = params.recordId;
2577
- const name = params.name;
2578
- const value = params.value;
2579
- const ttl = params.ttl;
2580
- const comment = params.comment;
2581
-
2582
- if (typeof domainId === 'undefined') {
2583
- throw new AppwriteException('Missing required parameter: "domainId"');
2584
- }
2585
- if (typeof recordId === 'undefined') {
2586
- throw new AppwriteException('Missing required parameter: "recordId"');
2587
- }
2588
- if (typeof name === 'undefined') {
2589
- throw new AppwriteException('Missing required parameter: "name"');
2590
- }
2591
- if (typeof value === 'undefined') {
2592
- throw new AppwriteException('Missing required parameter: "value"');
2593
- }
2594
- if (typeof ttl === 'undefined') {
2595
- throw new AppwriteException('Missing required parameter: "ttl"');
2596
- }
2597
-
2598
- const apiPath = '/domains/{domainId}/records/cname/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
2599
- const payload: Payload = {};
2600
- if (typeof name !== 'undefined') {
2601
- payload['name'] = name;
2602
- }
2603
- if (typeof value !== 'undefined') {
2604
- payload['value'] = value;
2605
- }
2606
- if (typeof ttl !== 'undefined') {
2607
- payload['ttl'] = ttl;
2608
- }
2609
- if (typeof comment !== 'undefined') {
2610
- payload['comment'] = comment;
2611
- }
2612
- const uri = new URL(this.client.config.endpoint + apiPath);
2613
-
2614
- const apiHeaders: { [header: string]: string } = {
2615
- 'content-type': 'application/json',
2616
- }
2617
-
2618
- return this.client.call(
2619
- 'put',
2620
- uri,
2621
- apiHeaders,
2622
- payload
2623
- );
2624
- }
2625
-
2626
- /**
2627
- * Create a new HTTPS record for the given domain. This record is used to configure HTTPS
2628
- * settings for your domain, enabling secure communication over SSL/TLS.
2629
- *
2630
- * @param {string} params.domainId - Domain unique ID.
2631
- * @param {string} params.name - Record name (subdomain).
2632
- * @param {string} params.value - Target for the HTTPS record.
2633
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2634
- * @param {string} params.comment - A comment for this record.
2635
- * @throws {AppwriteException}
2636
- * @returns {Promise<Models.DnsRecord>}
2637
- */
2638
- createRecordHTTPS(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2639
- /**
2640
- * Create a new HTTPS record for the given domain. This record is used to configure HTTPS
2641
- * settings for your domain, enabling secure communication over SSL/TLS.
2642
- *
2643
- * @param {string} domainId - Domain unique ID.
2644
- * @param {string} name - Record name (subdomain).
2645
- * @param {string} value - Target for the HTTPS record.
2646
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2647
- * @param {string} comment - A comment for this record.
2648
- * @throws {AppwriteException}
2649
- * @returns {Promise<Models.DnsRecord>}
2650
- * @deprecated Use the object parameter style method for a better developer experience.
2651
- */
2652
- createRecordHTTPS(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2653
- createRecordHTTPS(
2654
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
2655
- ...rest: [(string)?, (string)?, (number)?, (string)?]
2656
- ): Promise<Models.DnsRecord> {
2657
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
2658
-
2659
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2660
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
2661
- } else {
2662
- params = {
2663
- domainId: paramsOrFirst as string,
2664
- name: rest[0] as string,
2665
- value: rest[1] as string,
2666
- ttl: rest[2] as number,
2667
- comment: rest[3] as string
2668
- };
2669
- }
2670
-
2671
- const domainId = params.domainId;
2672
- const name = params.name;
2673
- const value = params.value;
2674
- const ttl = params.ttl;
2675
- const comment = params.comment;
2676
-
2677
- if (typeof domainId === 'undefined') {
2678
- throw new AppwriteException('Missing required parameter: "domainId"');
2679
- }
2680
- if (typeof name === 'undefined') {
2681
- throw new AppwriteException('Missing required parameter: "name"');
2682
- }
2683
- if (typeof value === 'undefined') {
2684
- throw new AppwriteException('Missing required parameter: "value"');
2685
- }
2686
- if (typeof ttl === 'undefined') {
2687
- throw new AppwriteException('Missing required parameter: "ttl"');
2688
- }
2689
-
2690
- const apiPath = '/domains/{domainId}/records/https'.replace('{domainId}', domainId);
2691
- const payload: Payload = {};
2692
- if (typeof name !== 'undefined') {
2693
- payload['name'] = name;
2694
- }
2695
- if (typeof value !== 'undefined') {
2696
- payload['value'] = value;
2697
- }
2698
- if (typeof ttl !== 'undefined') {
2699
- payload['ttl'] = ttl;
2700
- }
2701
- if (typeof comment !== 'undefined') {
2702
- payload['comment'] = comment;
2703
- }
2704
- const uri = new URL(this.client.config.endpoint + apiPath);
2705
-
2706
- const apiHeaders: { [header: string]: string } = {
2707
- 'content-type': 'application/json',
2708
- }
2709
-
2710
- return this.client.call(
2711
- 'post',
2712
- uri,
2713
- apiHeaders,
2714
- payload
2715
- );
2716
- }
2717
-
2718
- /**
2719
- * Update an existing HTTPS record for the given domain. This endpoint allows you to modify
2720
- * the properties of an HTTPS record associated with your domain, including the name (subdomain),
2721
- * target value, TTL, and optional comment.
2722
- *
2723
- * @param {string} params.domainId - Domain unique ID.
2724
- * @param {string} params.recordId - DNS record unique ID.
2725
- * @param {string} params.name - Record name (subdomain).
2726
- * @param {string} params.value - Target for the HTTPS record.
2727
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2728
- * @param {string} params.comment - A comment for this record.
2729
- * @throws {AppwriteException}
2730
- * @returns {Promise<Models.DnsRecord>}
2731
- */
2732
- updateRecordHTTPS(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
2733
- /**
2734
- * Update an existing HTTPS record for the given domain. This endpoint allows you to modify
2735
- * the properties of an HTTPS record associated with your domain, including the name (subdomain),
2736
- * target value, TTL, and optional comment.
2737
- *
2738
- * @param {string} domainId - Domain unique ID.
2739
- * @param {string} recordId - DNS record unique ID.
2740
- * @param {string} name - Record name (subdomain).
2741
- * @param {string} value - Target for the HTTPS record.
2742
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2743
- * @param {string} comment - A comment for this record.
2744
- * @throws {AppwriteException}
2745
- * @returns {Promise<Models.DnsRecord>}
2746
- * @deprecated Use the object parameter style method for a better developer experience.
2747
- */
2748
- updateRecordHTTPS(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
2749
- updateRecordHTTPS(
2750
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
2751
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
2752
- ): Promise<Models.DnsRecord> {
2753
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2754
-
2755
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2756
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
2757
- } else {
2758
- params = {
2759
- domainId: paramsOrFirst as string,
2760
- recordId: rest[0] as string,
2761
- name: rest[1] as string,
2762
- value: rest[2] as string,
2763
- ttl: rest[3] as number,
2764
- comment: rest[4] as string
2765
- };
2766
- }
2767
-
2768
- const domainId = params.domainId;
2769
- const recordId = params.recordId;
2770
- const name = params.name;
2771
- const value = params.value;
2772
- const ttl = params.ttl;
2773
- const comment = params.comment;
2774
-
2775
- if (typeof domainId === 'undefined') {
2776
- throw new AppwriteException('Missing required parameter: "domainId"');
2777
- }
2778
- if (typeof recordId === 'undefined') {
2779
- throw new AppwriteException('Missing required parameter: "recordId"');
2780
- }
2781
- if (typeof name === 'undefined') {
2782
- throw new AppwriteException('Missing required parameter: "name"');
2783
- }
2784
- if (typeof value === 'undefined') {
2785
- throw new AppwriteException('Missing required parameter: "value"');
2786
- }
2787
- if (typeof ttl === 'undefined') {
2788
- throw new AppwriteException('Missing required parameter: "ttl"');
2789
- }
2790
-
2791
- const apiPath = '/domains/{domainId}/records/https/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
2792
- const payload: Payload = {};
2793
- if (typeof name !== 'undefined') {
2794
- payload['name'] = name;
2795
- }
2796
- if (typeof value !== 'undefined') {
2797
- payload['value'] = value;
2798
- }
2799
- if (typeof ttl !== 'undefined') {
2800
- payload['ttl'] = ttl;
2801
- }
2802
- if (typeof comment !== 'undefined') {
2803
- payload['comment'] = comment;
2804
- }
2805
- const uri = new URL(this.client.config.endpoint + apiPath);
2806
-
2807
- const apiHeaders: { [header: string]: string } = {
2808
- 'content-type': 'application/json',
2809
- }
2810
-
2811
- return this.client.call(
2812
- 'put',
2813
- uri,
2814
- apiHeaders,
2815
- payload
2816
- );
2817
- }
2818
-
2819
- /**
2820
- * Create a new MX record for the given domain. MX records are used to define the mail servers responsible
2821
- * for accepting email messages for the domain. Multiple MX records can be created with different priorities.
2822
- * The priority parameter determines the order in which mail servers are used, with lower values indicating
2823
- * higher priority.
2824
- *
2825
- * @param {string} params.domainId - Domain unique ID.
2826
- * @param {string} params.name - Record name (subdomain).
2827
- * @param {string} params.value - Mail server domain for this MX record.
2828
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2829
- * @param {number} params.priority - MX priority.
2830
- * @param {string} params.comment - A comment for this record.
2831
- * @throws {AppwriteException}
2832
- * @returns {Promise<Models.DnsRecord>}
2833
- */
2834
- createRecordMX(params: { domainId: string, name: string, value: string, ttl: number, priority: number, comment?: string }): Promise<Models.DnsRecord>;
2835
- /**
2836
- * Create a new MX record for the given domain. MX records are used to define the mail servers responsible
2837
- * for accepting email messages for the domain. Multiple MX records can be created with different priorities.
2838
- * The priority parameter determines the order in which mail servers are used, with lower values indicating
2839
- * higher priority.
2840
- *
2841
- * @param {string} domainId - Domain unique ID.
2842
- * @param {string} name - Record name (subdomain).
2843
- * @param {string} value - Mail server domain for this MX record.
2844
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2845
- * @param {number} priority - MX priority.
2846
- * @param {string} comment - A comment for this record.
2847
- * @throws {AppwriteException}
2848
- * @returns {Promise<Models.DnsRecord>}
2849
- * @deprecated Use the object parameter style method for a better developer experience.
2850
- */
2851
- createRecordMX(domainId: string, name: string, value: string, ttl: number, priority: number, comment?: string): Promise<Models.DnsRecord>;
2852
- createRecordMX(
2853
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, priority: number, comment?: string } | string,
2854
- ...rest: [(string)?, (string)?, (number)?, (number)?, (string)?]
2855
- ): Promise<Models.DnsRecord> {
2856
- let params: { domainId: string, name: string, value: string, ttl: number, priority: number, comment?: string };
2857
-
2858
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2859
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, priority: number, comment?: string };
2860
- } else {
2861
- params = {
2862
- domainId: paramsOrFirst as string,
2863
- name: rest[0] as string,
2864
- value: rest[1] as string,
2865
- ttl: rest[2] as number,
2866
- priority: rest[3] as number,
2867
- comment: rest[4] as string
2868
- };
2869
- }
2870
-
2871
- const domainId = params.domainId;
2872
- const name = params.name;
2873
- const value = params.value;
2874
- const ttl = params.ttl;
2875
- const priority = params.priority;
2876
- const comment = params.comment;
2877
-
2878
- if (typeof domainId === 'undefined') {
2879
- throw new AppwriteException('Missing required parameter: "domainId"');
2880
- }
2881
- if (typeof name === 'undefined') {
2882
- throw new AppwriteException('Missing required parameter: "name"');
2883
- }
2884
- if (typeof value === 'undefined') {
2885
- throw new AppwriteException('Missing required parameter: "value"');
2886
- }
2887
- if (typeof ttl === 'undefined') {
2888
- throw new AppwriteException('Missing required parameter: "ttl"');
2889
- }
2890
- if (typeof priority === 'undefined') {
2891
- throw new AppwriteException('Missing required parameter: "priority"');
2892
- }
2893
-
2894
- const apiPath = '/domains/{domainId}/records/mx'.replace('{domainId}', domainId);
2895
- const payload: Payload = {};
2896
- if (typeof name !== 'undefined') {
2897
- payload['name'] = name;
2898
- }
2899
- if (typeof value !== 'undefined') {
2900
- payload['value'] = value;
2901
- }
2902
- if (typeof ttl !== 'undefined') {
2903
- payload['ttl'] = ttl;
2904
- }
2905
- if (typeof priority !== 'undefined') {
2906
- payload['priority'] = priority;
2907
- }
2908
- if (typeof comment !== 'undefined') {
2909
- payload['comment'] = comment;
2910
- }
2911
- const uri = new URL(this.client.config.endpoint + apiPath);
2912
-
2913
- const apiHeaders: { [header: string]: string } = {
2914
- 'content-type': 'application/json',
2915
- }
2916
-
2917
- return this.client.call(
2918
- 'post',
2919
- uri,
2920
- apiHeaders,
2921
- payload
2922
- );
2923
- }
2924
-
2925
- /**
2926
- * Update an existing MX record for the given domain.
2927
- *
2928
- * @param {string} params.domainId - Domain unique ID.
2929
- * @param {string} params.recordId - DNS record unique ID.
2930
- * @param {string} params.name - Record name (subdomain).
2931
- * @param {string} params.value - Mail server domain for this MX record.
2932
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
2933
- * @param {number} params.priority - MX priority.
2934
- * @param {string} params.comment - A comment for this record.
2935
- * @throws {AppwriteException}
2936
- * @returns {Promise<Models.DnsRecord>}
2937
- */
2938
- updateRecordMX(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, comment?: string }): Promise<Models.DnsRecord>;
2939
- /**
2940
- * Update an existing MX record for the given domain.
2941
- *
2942
- * @param {string} domainId - Domain unique ID.
2943
- * @param {string} recordId - DNS record unique ID.
2944
- * @param {string} name - Record name (subdomain).
2945
- * @param {string} value - Mail server domain for this MX record.
2946
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
2947
- * @param {number} priority - MX priority.
2948
- * @param {string} comment - A comment for this record.
2949
- * @throws {AppwriteException}
2950
- * @returns {Promise<Models.DnsRecord>}
2951
- * @deprecated Use the object parameter style method for a better developer experience.
2952
- */
2953
- updateRecordMX(domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, comment?: string): Promise<Models.DnsRecord>;
2954
- updateRecordMX(
2955
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, comment?: string } | string,
2956
- ...rest: [(string)?, (string)?, (string)?, (number)?, (number)?, (string)?]
2957
- ): Promise<Models.DnsRecord> {
2958
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, comment?: string };
2959
-
2960
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
2961
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, comment?: string };
2962
- } else {
2963
- params = {
2964
- domainId: paramsOrFirst as string,
2965
- recordId: rest[0] as string,
2966
- name: rest[1] as string,
2967
- value: rest[2] as string,
2968
- ttl: rest[3] as number,
2969
- priority: rest[4] as number,
2970
- comment: rest[5] as string
2971
- };
2972
- }
2973
-
2974
- const domainId = params.domainId;
2975
- const recordId = params.recordId;
2976
- const name = params.name;
2977
- const value = params.value;
2978
- const ttl = params.ttl;
2979
- const priority = params.priority;
2980
- const comment = params.comment;
2981
-
2982
- if (typeof domainId === 'undefined') {
2983
- throw new AppwriteException('Missing required parameter: "domainId"');
2984
- }
2985
- if (typeof recordId === 'undefined') {
2986
- throw new AppwriteException('Missing required parameter: "recordId"');
2987
- }
2988
- if (typeof name === 'undefined') {
2989
- throw new AppwriteException('Missing required parameter: "name"');
2990
- }
2991
- if (typeof value === 'undefined') {
2992
- throw new AppwriteException('Missing required parameter: "value"');
2993
- }
2994
- if (typeof ttl === 'undefined') {
2995
- throw new AppwriteException('Missing required parameter: "ttl"');
2996
- }
2997
- if (typeof priority === 'undefined') {
2998
- throw new AppwriteException('Missing required parameter: "priority"');
2999
- }
3000
-
3001
- const apiPath = '/domains/{domainId}/records/mx/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3002
- const payload: Payload = {};
3003
- if (typeof name !== 'undefined') {
3004
- payload['name'] = name;
3005
- }
3006
- if (typeof value !== 'undefined') {
3007
- payload['value'] = value;
3008
- }
3009
- if (typeof ttl !== 'undefined') {
3010
- payload['ttl'] = ttl;
3011
- }
3012
- if (typeof priority !== 'undefined') {
3013
- payload['priority'] = priority;
3014
- }
3015
- if (typeof comment !== 'undefined') {
3016
- payload['comment'] = comment;
3017
- }
3018
- const uri = new URL(this.client.config.endpoint + apiPath);
3019
-
3020
- const apiHeaders: { [header: string]: string } = {
3021
- 'content-type': 'application/json',
3022
- }
3023
-
3024
- return this.client.call(
3025
- 'put',
3026
- uri,
3027
- apiHeaders,
3028
- payload
3029
- );
3030
- }
3031
-
3032
- /**
3033
- * Create a new NS record for the given domain. NS records specify the nameservers that are used
3034
- * to resolve the domain name to IP addresses. Each domain can have multiple NS records.
3035
- *
3036
- * @param {string} params.domainId - Domain unique ID.
3037
- * @param {string} params.name - Record name (subdomain).
3038
- * @param {string} params.value - Nameserver target for this NS record.
3039
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3040
- * @param {string} params.comment - A comment for this record.
3041
- * @throws {AppwriteException}
3042
- * @returns {Promise<Models.DnsRecord>}
3043
- */
3044
- createRecordNS(params: { domainId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
3045
- /**
3046
- * Create a new NS record for the given domain. NS records specify the nameservers that are used
3047
- * to resolve the domain name to IP addresses. Each domain can have multiple NS records.
3048
- *
3049
- * @param {string} domainId - Domain unique ID.
3050
- * @param {string} name - Record name (subdomain).
3051
- * @param {string} value - Nameserver target for this NS record.
3052
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3053
- * @param {string} comment - A comment for this record.
3054
- * @throws {AppwriteException}
3055
- * @returns {Promise<Models.DnsRecord>}
3056
- * @deprecated Use the object parameter style method for a better developer experience.
3057
- */
3058
- createRecordNS(domainId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
3059
- createRecordNS(
3060
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, comment?: string } | string,
3061
- ...rest: [(string)?, (string)?, (number)?, (string)?]
3062
- ): Promise<Models.DnsRecord> {
3063
- let params: { domainId: string, name: string, value: string, ttl: number, comment?: string };
3064
-
3065
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3066
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, comment?: string };
3067
- } else {
3068
- params = {
3069
- domainId: paramsOrFirst as string,
3070
- name: rest[0] as string,
3071
- value: rest[1] as string,
3072
- ttl: rest[2] as number,
3073
- comment: rest[3] as string
3074
- };
3075
- }
3076
-
3077
- const domainId = params.domainId;
3078
- const name = params.name;
3079
- const value = params.value;
3080
- const ttl = params.ttl;
3081
- const comment = params.comment;
3082
-
3083
- if (typeof domainId === 'undefined') {
3084
- throw new AppwriteException('Missing required parameter: "domainId"');
3085
- }
3086
- if (typeof name === 'undefined') {
3087
- throw new AppwriteException('Missing required parameter: "name"');
3088
- }
3089
- if (typeof value === 'undefined') {
3090
- throw new AppwriteException('Missing required parameter: "value"');
3091
- }
3092
- if (typeof ttl === 'undefined') {
3093
- throw new AppwriteException('Missing required parameter: "ttl"');
3094
- }
3095
-
3096
- const apiPath = '/domains/{domainId}/records/ns'.replace('{domainId}', domainId);
3097
- const payload: Payload = {};
3098
- if (typeof name !== 'undefined') {
3099
- payload['name'] = name;
3100
- }
3101
- if (typeof value !== 'undefined') {
3102
- payload['value'] = value;
3103
- }
3104
- if (typeof ttl !== 'undefined') {
3105
- payload['ttl'] = ttl;
3106
- }
3107
- if (typeof comment !== 'undefined') {
3108
- payload['comment'] = comment;
3109
- }
3110
- const uri = new URL(this.client.config.endpoint + apiPath);
3111
-
3112
- const apiHeaders: { [header: string]: string } = {
3113
- 'content-type': 'application/json',
3114
- }
3115
-
3116
- return this.client.call(
3117
- 'post',
3118
- uri,
3119
- apiHeaders,
3120
- payload
3121
- );
3122
- }
3123
-
3124
- /**
3125
- * Update an existing NS record for the given domain. This endpoint allows you to modify
3126
- * the properties of an NS (nameserver) record associated with your domain. You can update
3127
- * the record name (subdomain), target nameserver value, TTL, and add or modify comments
3128
- * for better record management.
3129
- *
3130
- * @param {string} params.domainId - Domain unique ID.
3131
- * @param {string} params.recordId - DNS record unique ID.
3132
- * @param {string} params.name - Record name (subdomain).
3133
- * @param {string} params.value - Nameserver target for this NS record.
3134
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3135
- * @param {string} params.comment - A comment for this record.
3136
- * @throws {AppwriteException}
3137
- * @returns {Promise<Models.DnsRecord>}
3138
- */
3139
- updateRecordNS(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
3140
- /**
3141
- * Update an existing NS record for the given domain. This endpoint allows you to modify
3142
- * the properties of an NS (nameserver) record associated with your domain. You can update
3143
- * the record name (subdomain), target nameserver value, TTL, and add or modify comments
3144
- * for better record management.
3145
- *
3146
- * @param {string} domainId - Domain unique ID.
3147
- * @param {string} recordId - DNS record unique ID.
3148
- * @param {string} name - Record name (subdomain).
3149
- * @param {string} value - Nameserver target for this NS record.
3150
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3151
- * @param {string} comment - A comment for this record.
3152
- * @throws {AppwriteException}
3153
- * @returns {Promise<Models.DnsRecord>}
3154
- * @deprecated Use the object parameter style method for a better developer experience.
3155
- */
3156
- updateRecordNS(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
3157
- updateRecordNS(
3158
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
3159
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
3160
- ): Promise<Models.DnsRecord> {
3161
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
3162
-
3163
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3164
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
3165
- } else {
3166
- params = {
3167
- domainId: paramsOrFirst as string,
3168
- recordId: rest[0] as string,
3169
- name: rest[1] as string,
3170
- value: rest[2] as string,
3171
- ttl: rest[3] as number,
3172
- comment: rest[4] as string
3173
- };
3174
- }
3175
-
3176
- const domainId = params.domainId;
3177
- const recordId = params.recordId;
3178
- const name = params.name;
3179
- const value = params.value;
3180
- const ttl = params.ttl;
3181
- const comment = params.comment;
3182
-
3183
- if (typeof domainId === 'undefined') {
3184
- throw new AppwriteException('Missing required parameter: "domainId"');
3185
- }
3186
- if (typeof recordId === 'undefined') {
3187
- throw new AppwriteException('Missing required parameter: "recordId"');
3188
- }
3189
- if (typeof name === 'undefined') {
3190
- throw new AppwriteException('Missing required parameter: "name"');
3191
- }
3192
- if (typeof value === 'undefined') {
3193
- throw new AppwriteException('Missing required parameter: "value"');
3194
- }
3195
- if (typeof ttl === 'undefined') {
3196
- throw new AppwriteException('Missing required parameter: "ttl"');
3197
- }
3198
-
3199
- const apiPath = '/domains/{domainId}/records/ns/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3200
- const payload: Payload = {};
3201
- if (typeof name !== 'undefined') {
3202
- payload['name'] = name;
3203
- }
3204
- if (typeof value !== 'undefined') {
3205
- payload['value'] = value;
3206
- }
3207
- if (typeof ttl !== 'undefined') {
3208
- payload['ttl'] = ttl;
3209
- }
3210
- if (typeof comment !== 'undefined') {
3211
- payload['comment'] = comment;
3212
- }
3213
- const uri = new URL(this.client.config.endpoint + apiPath);
3214
-
3215
- const apiHeaders: { [header: string]: string } = {
3216
- 'content-type': 'application/json',
3217
- }
3218
-
3219
- return this.client.call(
3220
- 'put',
3221
- uri,
3222
- apiHeaders,
3223
- payload
3224
- );
3225
- }
3226
-
3227
- /**
3228
- * Create a new SRV record for the given domain. SRV records are used to define the location
3229
- * of servers for specific services. For example, they can be used to specify which server
3230
- * handles a specific service like SIP or XMPP for the domain.
3231
- *
3232
- * @param {string} params.domainId - Domain unique ID.
3233
- * @param {string} params.name - Record name (service name).
3234
- * @param {string} params.value - Target hostname for this SRV record.
3235
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3236
- * @param {number} params.priority - Record priority.
3237
- * @param {number} params.weight - Record weight.
3238
- * @param {number} params.port - Port number for the service.
3239
- * @param {string} params.comment - A comment for this record.
3240
- * @throws {AppwriteException}
3241
- * @returns {Promise<Models.DnsRecord>}
3242
- */
3243
- createRecordSRV(params: { domainId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string }): Promise<Models.DnsRecord>;
3244
- /**
3245
- * Create a new SRV record for the given domain. SRV records are used to define the location
3246
- * of servers for specific services. For example, they can be used to specify which server
3247
- * handles a specific service like SIP or XMPP for the domain.
3248
- *
3249
- * @param {string} domainId - Domain unique ID.
3250
- * @param {string} name - Record name (service name).
3251
- * @param {string} value - Target hostname for this SRV record.
3252
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3253
- * @param {number} priority - Record priority.
3254
- * @param {number} weight - Record weight.
3255
- * @param {number} port - Port number for the service.
3256
- * @param {string} comment - A comment for this record.
3257
- * @throws {AppwriteException}
3258
- * @returns {Promise<Models.DnsRecord>}
3259
- * @deprecated Use the object parameter style method for a better developer experience.
3260
- */
3261
- createRecordSRV(domainId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string): Promise<Models.DnsRecord>;
3262
- createRecordSRV(
3263
- paramsOrFirst: { domainId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string } | string,
3264
- ...rest: [(string)?, (string)?, (number)?, (number)?, (number)?, (number)?, (string)?]
3265
- ): Promise<Models.DnsRecord> {
3266
- let params: { domainId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string };
3267
-
3268
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3269
- params = (paramsOrFirst || {}) as { domainId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string };
3270
- } else {
3271
- params = {
3272
- domainId: paramsOrFirst as string,
3273
- name: rest[0] as string,
3274
- value: rest[1] as string,
3275
- ttl: rest[2] as number,
3276
- priority: rest[3] as number,
3277
- weight: rest[4] as number,
3278
- port: rest[5] as number,
3279
- comment: rest[6] as string
3280
- };
3281
- }
3282
-
3283
- const domainId = params.domainId;
3284
- const name = params.name;
3285
- const value = params.value;
3286
- const ttl = params.ttl;
3287
- const priority = params.priority;
3288
- const weight = params.weight;
3289
- const port = params.port;
3290
- const comment = params.comment;
3291
-
3292
- if (typeof domainId === 'undefined') {
3293
- throw new AppwriteException('Missing required parameter: "domainId"');
3294
- }
3295
- if (typeof name === 'undefined') {
3296
- throw new AppwriteException('Missing required parameter: "name"');
3297
- }
3298
- if (typeof value === 'undefined') {
3299
- throw new AppwriteException('Missing required parameter: "value"');
3300
- }
3301
- if (typeof ttl === 'undefined') {
3302
- throw new AppwriteException('Missing required parameter: "ttl"');
3303
- }
3304
- if (typeof priority === 'undefined') {
3305
- throw new AppwriteException('Missing required parameter: "priority"');
3306
- }
3307
- if (typeof weight === 'undefined') {
3308
- throw new AppwriteException('Missing required parameter: "weight"');
3309
- }
3310
- if (typeof port === 'undefined') {
3311
- throw new AppwriteException('Missing required parameter: "port"');
3312
- }
3313
-
3314
- const apiPath = '/domains/{domainId}/records/srv'.replace('{domainId}', domainId);
3315
- const payload: Payload = {};
3316
- if (typeof name !== 'undefined') {
3317
- payload['name'] = name;
3318
- }
3319
- if (typeof value !== 'undefined') {
3320
- payload['value'] = value;
3321
- }
3322
- if (typeof ttl !== 'undefined') {
3323
- payload['ttl'] = ttl;
3324
- }
3325
- if (typeof priority !== 'undefined') {
3326
- payload['priority'] = priority;
3327
- }
3328
- if (typeof weight !== 'undefined') {
3329
- payload['weight'] = weight;
3330
- }
3331
- if (typeof port !== 'undefined') {
3332
- payload['port'] = port;
3333
- }
3334
- if (typeof comment !== 'undefined') {
3335
- payload['comment'] = comment;
3336
- }
3337
- const uri = new URL(this.client.config.endpoint + apiPath);
3338
-
3339
- const apiHeaders: { [header: string]: string } = {
3340
- 'content-type': 'application/json',
3341
- }
3342
-
3343
- return this.client.call(
3344
- 'post',
3345
- uri,
3346
- apiHeaders,
3347
- payload
3348
- );
3349
- }
3350
-
3351
- /**
3352
- * Update an existing SRV record for the given domain.
3353
- *
3354
- * Required parameters:
3355
- * - domainId: Domain unique ID
3356
- * - recordId: DNS record unique ID
3357
- * - name: Record name (service name)
3358
- * - value: Target hostname for this SRV record
3359
- * - ttl: Time to live, in seconds
3360
- * - priority: Record priority
3361
- * - weight: Record weight
3362
- * - port: Port number for the service
3363
- *
3364
- * Optional parameters:
3365
- * - comment: A comment for this record
3366
- *
3367
- * @param {string} params.domainId - Domain unique ID.
3368
- * @param {string} params.recordId - DNS record unique ID.
3369
- * @param {string} params.name - Record name (service name).
3370
- * @param {string} params.value - Target hostname for this SRV record.
3371
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3372
- * @param {number} params.priority - Record priority.
3373
- * @param {number} params.weight - Record weight.
3374
- * @param {number} params.port - Port number for the service.
3375
- * @param {string} params.comment - A comment for this record.
3376
- * @throws {AppwriteException}
3377
- * @returns {Promise<Models.DnsRecord>}
3378
- */
3379
- updateRecordSRV(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string }): Promise<Models.DnsRecord>;
3380
- /**
3381
- * Update an existing SRV record for the given domain.
3382
- *
3383
- * Required parameters:
3384
- * - domainId: Domain unique ID
3385
- * - recordId: DNS record unique ID
3386
- * - name: Record name (service name)
3387
- * - value: Target hostname for this SRV record
3388
- * - ttl: Time to live, in seconds
3389
- * - priority: Record priority
3390
- * - weight: Record weight
3391
- * - port: Port number for the service
3392
- *
3393
- * Optional parameters:
3394
- * - comment: A comment for this record
3395
- *
3396
- * @param {string} domainId - Domain unique ID.
3397
- * @param {string} recordId - DNS record unique ID.
3398
- * @param {string} name - Record name (service name).
3399
- * @param {string} value - Target hostname for this SRV record.
3400
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3401
- * @param {number} priority - Record priority.
3402
- * @param {number} weight - Record weight.
3403
- * @param {number} port - Port number for the service.
3404
- * @param {string} comment - A comment for this record.
3405
- * @throws {AppwriteException}
3406
- * @returns {Promise<Models.DnsRecord>}
3407
- * @deprecated Use the object parameter style method for a better developer experience.
3408
- */
3409
- updateRecordSRV(domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string): Promise<Models.DnsRecord>;
3410
- updateRecordSRV(
3411
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string } | string,
3412
- ...rest: [(string)?, (string)?, (string)?, (number)?, (number)?, (number)?, (number)?, (string)?]
3413
- ): Promise<Models.DnsRecord> {
3414
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string };
3415
-
3416
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3417
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, priority: number, weight: number, port: number, comment?: string };
3418
- } else {
3419
- params = {
3420
- domainId: paramsOrFirst as string,
3421
- recordId: rest[0] as string,
3422
- name: rest[1] as string,
3423
- value: rest[2] as string,
3424
- ttl: rest[3] as number,
3425
- priority: rest[4] as number,
3426
- weight: rest[5] as number,
3427
- port: rest[6] as number,
3428
- comment: rest[7] as string
3429
- };
3430
- }
3431
-
3432
- const domainId = params.domainId;
3433
- const recordId = params.recordId;
3434
- const name = params.name;
3435
- const value = params.value;
3436
- const ttl = params.ttl;
3437
- const priority = params.priority;
3438
- const weight = params.weight;
3439
- const port = params.port;
3440
- const comment = params.comment;
3441
-
3442
- if (typeof domainId === 'undefined') {
3443
- throw new AppwriteException('Missing required parameter: "domainId"');
3444
- }
3445
- if (typeof recordId === 'undefined') {
3446
- throw new AppwriteException('Missing required parameter: "recordId"');
3447
- }
3448
- if (typeof name === 'undefined') {
3449
- throw new AppwriteException('Missing required parameter: "name"');
3450
- }
3451
- if (typeof value === 'undefined') {
3452
- throw new AppwriteException('Missing required parameter: "value"');
3453
- }
3454
- if (typeof ttl === 'undefined') {
3455
- throw new AppwriteException('Missing required parameter: "ttl"');
3456
- }
3457
- if (typeof priority === 'undefined') {
3458
- throw new AppwriteException('Missing required parameter: "priority"');
3459
- }
3460
- if (typeof weight === 'undefined') {
3461
- throw new AppwriteException('Missing required parameter: "weight"');
3462
- }
3463
- if (typeof port === 'undefined') {
3464
- throw new AppwriteException('Missing required parameter: "port"');
3465
- }
3466
-
3467
- const apiPath = '/domains/{domainId}/records/srv/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3468
- const payload: Payload = {};
3469
- if (typeof name !== 'undefined') {
3470
- payload['name'] = name;
3471
- }
3472
- if (typeof value !== 'undefined') {
3473
- payload['value'] = value;
3474
- }
3475
- if (typeof ttl !== 'undefined') {
3476
- payload['ttl'] = ttl;
3477
- }
3478
- if (typeof priority !== 'undefined') {
3479
- payload['priority'] = priority;
3480
- }
3481
- if (typeof weight !== 'undefined') {
3482
- payload['weight'] = weight;
3483
- }
3484
- if (typeof port !== 'undefined') {
3485
- payload['port'] = port;
3486
- }
3487
- if (typeof comment !== 'undefined') {
3488
- payload['comment'] = comment;
3489
- }
3490
- const uri = new URL(this.client.config.endpoint + apiPath);
3491
-
3492
- const apiHeaders: { [header: string]: string } = {
3493
- 'content-type': 'application/json',
3494
- }
3495
-
3496
- return this.client.call(
3497
- 'put',
3498
- uri,
3499
- apiHeaders,
3500
- payload
3501
- );
3502
- }
3503
-
3504
- /**
3505
- * Create a new TXT record for the given domain. TXT records can be used
3506
- * to provide additional information about your domain, such as domain
3507
- * verification records, SPF records, or DKIM records.
3508
- *
3509
- * @param {string} params.domainId - Domain unique ID.
3510
- * @param {string} params.name - Record name (subdomain) for the TXT record.
3511
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3512
- * @param {string} params.value - TXT record value.
3513
- * @param {string} params.comment - A comment for this record.
3514
- * @throws {AppwriteException}
3515
- * @returns {Promise<Models.DnsRecord>}
3516
- */
3517
- createRecordTXT(params: { domainId: string, name: string, ttl: number, value?: string, comment?: string }): Promise<Models.DnsRecord>;
3518
- /**
3519
- * Create a new TXT record for the given domain. TXT records can be used
3520
- * to provide additional information about your domain, such as domain
3521
- * verification records, SPF records, or DKIM records.
3522
- *
3523
- * @param {string} domainId - Domain unique ID.
3524
- * @param {string} name - Record name (subdomain) for the TXT record.
3525
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3526
- * @param {string} value - TXT record value.
3527
- * @param {string} comment - A comment for this record.
3528
- * @throws {AppwriteException}
3529
- * @returns {Promise<Models.DnsRecord>}
3530
- * @deprecated Use the object parameter style method for a better developer experience.
3531
- */
3532
- createRecordTXT(domainId: string, name: string, ttl: number, value?: string, comment?: string): Promise<Models.DnsRecord>;
3533
- createRecordTXT(
3534
- paramsOrFirst: { domainId: string, name: string, ttl: number, value?: string, comment?: string } | string,
3535
- ...rest: [(string)?, (number)?, (string)?, (string)?]
3536
- ): Promise<Models.DnsRecord> {
3537
- let params: { domainId: string, name: string, ttl: number, value?: string, comment?: string };
3538
-
3539
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3540
- params = (paramsOrFirst || {}) as { domainId: string, name: string, ttl: number, value?: string, comment?: string };
3541
- } else {
3542
- params = {
3543
- domainId: paramsOrFirst as string,
3544
- name: rest[0] as string,
3545
- ttl: rest[1] as number,
3546
- value: rest[2] as string,
3547
- comment: rest[3] as string
3548
- };
3549
- }
3550
-
3551
- const domainId = params.domainId;
3552
- const name = params.name;
3553
- const ttl = params.ttl;
3554
- const value = params.value;
3555
- const comment = params.comment;
3556
-
3557
- if (typeof domainId === 'undefined') {
3558
- throw new AppwriteException('Missing required parameter: "domainId"');
3559
- }
3560
- if (typeof name === 'undefined') {
3561
- throw new AppwriteException('Missing required parameter: "name"');
3562
- }
3563
- if (typeof ttl === 'undefined') {
3564
- throw new AppwriteException('Missing required parameter: "ttl"');
3565
- }
3566
-
3567
- const apiPath = '/domains/{domainId}/records/txt'.replace('{domainId}', domainId);
3568
- const payload: Payload = {};
3569
- if (typeof name !== 'undefined') {
3570
- payload['name'] = name;
3571
- }
3572
- if (typeof value !== 'undefined') {
3573
- payload['value'] = value;
3574
- }
3575
- if (typeof ttl !== 'undefined') {
3576
- payload['ttl'] = ttl;
3577
- }
3578
- if (typeof comment !== 'undefined') {
3579
- payload['comment'] = comment;
3580
- }
3581
- const uri = new URL(this.client.config.endpoint + apiPath);
3582
-
3583
- const apiHeaders: { [header: string]: string } = {
3584
- 'content-type': 'application/json',
3585
- }
3586
-
3587
- return this.client.call(
3588
- 'post',
3589
- uri,
3590
- apiHeaders,
3591
- payload
3592
- );
3593
- }
3594
-
3595
- /**
3596
- * Update an existing TXT record for the given domain.
3597
- *
3598
- * Update the TXT record details for a specific domain by providing the domain ID,
3599
- * record ID, and the new record configuration including name, value, TTL, and an optional comment.
3600
- *
3601
- * @param {string} params.domainId - Domain unique ID.
3602
- * @param {string} params.recordId - DNS record unique ID.
3603
- * @param {string} params.name - Record name (subdomain) for the TXT record.
3604
- * @param {string} params.value - TXT record value.
3605
- * @param {number} params.ttl - Time to live, in seconds. Must be greater than 0.
3606
- * @param {string} params.comment - A comment for this record.
3607
- * @throws {AppwriteException}
3608
- * @returns {Promise<Models.DnsRecord>}
3609
- */
3610
- updateRecordTXT(params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string }): Promise<Models.DnsRecord>;
3611
- /**
3612
- * Update an existing TXT record for the given domain.
3613
- *
3614
- * Update the TXT record details for a specific domain by providing the domain ID,
3615
- * record ID, and the new record configuration including name, value, TTL, and an optional comment.
3616
- *
3617
- * @param {string} domainId - Domain unique ID.
3618
- * @param {string} recordId - DNS record unique ID.
3619
- * @param {string} name - Record name (subdomain) for the TXT record.
3620
- * @param {string} value - TXT record value.
3621
- * @param {number} ttl - Time to live, in seconds. Must be greater than 0.
3622
- * @param {string} comment - A comment for this record.
3623
- * @throws {AppwriteException}
3624
- * @returns {Promise<Models.DnsRecord>}
3625
- * @deprecated Use the object parameter style method for a better developer experience.
3626
- */
3627
- updateRecordTXT(domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string): Promise<Models.DnsRecord>;
3628
- updateRecordTXT(
3629
- paramsOrFirst: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string } | string,
3630
- ...rest: [(string)?, (string)?, (string)?, (number)?, (string)?]
3631
- ): Promise<Models.DnsRecord> {
3632
- let params: { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
3633
-
3634
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3635
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string, name: string, value: string, ttl: number, comment?: string };
3636
- } else {
3637
- params = {
3638
- domainId: paramsOrFirst as string,
3639
- recordId: rest[0] as string,
3640
- name: rest[1] as string,
3641
- value: rest[2] as string,
3642
- ttl: rest[3] as number,
3643
- comment: rest[4] as string
3644
- };
3645
- }
3646
-
3647
- const domainId = params.domainId;
3648
- const recordId = params.recordId;
3649
- const name = params.name;
3650
- const value = params.value;
3651
- const ttl = params.ttl;
3652
- const comment = params.comment;
3653
-
3654
- if (typeof domainId === 'undefined') {
3655
- throw new AppwriteException('Missing required parameter: "domainId"');
3656
- }
3657
- if (typeof recordId === 'undefined') {
3658
- throw new AppwriteException('Missing required parameter: "recordId"');
3659
- }
3660
- if (typeof name === 'undefined') {
3661
- throw new AppwriteException('Missing required parameter: "name"');
3662
- }
3663
- if (typeof value === 'undefined') {
3664
- throw new AppwriteException('Missing required parameter: "value"');
3665
- }
3666
- if (typeof ttl === 'undefined') {
3667
- throw new AppwriteException('Missing required parameter: "ttl"');
3668
- }
3669
-
3670
- const apiPath = '/domains/{domainId}/records/txt/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3671
- const payload: Payload = {};
3672
- if (typeof name !== 'undefined') {
3673
- payload['name'] = name;
3674
- }
3675
- if (typeof value !== 'undefined') {
3676
- payload['value'] = value;
3677
- }
3678
- if (typeof ttl !== 'undefined') {
3679
- payload['ttl'] = ttl;
3680
- }
3681
- if (typeof comment !== 'undefined') {
3682
- payload['comment'] = comment;
3683
- }
3684
- const uri = new URL(this.client.config.endpoint + apiPath);
3685
-
3686
- const apiHeaders: { [header: string]: string } = {
3687
- 'content-type': 'application/json',
3688
- }
3689
-
3690
- return this.client.call(
3691
- 'put',
3692
- uri,
3693
- apiHeaders,
3694
- payload
3695
- );
3696
- }
3697
-
3698
- /**
3699
- * Get a single DNS record for a given domain by record ID.
3700
- *
3701
- * This endpoint allows you to retrieve a specific DNS record associated with a domain
3702
- * using its unique identifier. The record contains information about the DNS configuration
3703
- * such as type, value, and TTL settings.
3704
- *
3705
- * @param {string} params.domainId - Domain unique ID.
3706
- * @param {string} params.recordId - DNS record unique ID.
3707
- * @throws {AppwriteException}
3708
- * @returns {Promise<Models.DnsRecord>}
3709
- */
3710
- getRecord(params: { domainId: string, recordId: string }): Promise<Models.DnsRecord>;
3711
- /**
3712
- * Get a single DNS record for a given domain by record ID.
3713
- *
3714
- * This endpoint allows you to retrieve a specific DNS record associated with a domain
3715
- * using its unique identifier. The record contains information about the DNS configuration
3716
- * such as type, value, and TTL settings.
3717
- *
3718
- * @param {string} domainId - Domain unique ID.
3719
- * @param {string} recordId - DNS record unique ID.
3720
- * @throws {AppwriteException}
3721
- * @returns {Promise<Models.DnsRecord>}
3722
- * @deprecated Use the object parameter style method for a better developer experience.
3723
- */
3724
- getRecord(domainId: string, recordId: string): Promise<Models.DnsRecord>;
3725
- getRecord(
3726
- paramsOrFirst: { domainId: string, recordId: string } | string,
3727
- ...rest: [(string)?]
3728
- ): Promise<Models.DnsRecord> {
3729
- let params: { domainId: string, recordId: string };
3730
-
3731
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3732
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string };
3733
- } else {
3734
- params = {
3735
- domainId: paramsOrFirst as string,
3736
- recordId: rest[0] as string
3737
- };
3738
- }
3739
-
3740
- const domainId = params.domainId;
3741
- const recordId = params.recordId;
3742
-
3743
- if (typeof domainId === 'undefined') {
3744
- throw new AppwriteException('Missing required parameter: "domainId"');
3745
- }
3746
- if (typeof recordId === 'undefined') {
3747
- throw new AppwriteException('Missing required parameter: "recordId"');
3748
- }
3749
-
3750
- const apiPath = '/domains/{domainId}/records/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3751
- const payload: Payload = {};
3752
- const uri = new URL(this.client.config.endpoint + apiPath);
3753
-
3754
- const apiHeaders: { [header: string]: string } = {
3755
- }
3756
-
3757
- return this.client.call(
3758
- 'get',
3759
- uri,
3760
- apiHeaders,
3761
- payload
3762
- );
3763
- }
3764
-
3765
- /**
3766
- * Delete a DNS record for the given domain. This endpoint allows you to delete an existing DNS record
3767
- * from a specific domain.
3768
- *
3769
- * @param {string} params.domainId - Domain unique ID.
3770
- * @param {string} params.recordId - DNS record unique ID.
3771
- * @throws {AppwriteException}
3772
- * @returns {Promise<{}>}
3773
- */
3774
- deleteRecord(params: { domainId: string, recordId: string }): Promise<{}>;
3775
- /**
3776
- * Delete a DNS record for the given domain. This endpoint allows you to delete an existing DNS record
3777
- * from a specific domain.
3778
- *
3779
- * @param {string} domainId - Domain unique ID.
3780
- * @param {string} recordId - DNS record unique ID.
3781
- * @throws {AppwriteException}
3782
- * @returns {Promise<{}>}
3783
- * @deprecated Use the object parameter style method for a better developer experience.
3784
- */
3785
- deleteRecord(domainId: string, recordId: string): Promise<{}>;
3786
- deleteRecord(
3787
- paramsOrFirst: { domainId: string, recordId: string } | string,
3788
- ...rest: [(string)?]
3789
- ): Promise<{}> {
3790
- let params: { domainId: string, recordId: string };
3791
-
3792
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3793
- params = (paramsOrFirst || {}) as { domainId: string, recordId: string };
3794
- } else {
3795
- params = {
3796
- domainId: paramsOrFirst as string,
3797
- recordId: rest[0] as string
3798
- };
3799
- }
3800
-
3801
- const domainId = params.domainId;
3802
- const recordId = params.recordId;
3803
-
3804
- if (typeof domainId === 'undefined') {
3805
- throw new AppwriteException('Missing required parameter: "domainId"');
3806
- }
3807
- if (typeof recordId === 'undefined') {
3808
- throw new AppwriteException('Missing required parameter: "recordId"');
3809
- }
3810
-
3811
- const apiPath = '/domains/{domainId}/records/{recordId}'.replace('{domainId}', domainId).replace('{recordId}', recordId);
3812
- const payload: Payload = {};
3813
- const uri = new URL(this.client.config.endpoint + apiPath);
3814
-
3815
- const apiHeaders: { [header: string]: string } = {
3816
- 'content-type': 'application/json',
3817
- }
3818
-
3819
- return this.client.call(
3820
- 'delete',
3821
- uri,
3822
- apiHeaders,
3823
- payload
3824
- );
3825
- }
3826
-
3827
- /**
3828
- * Update the team ID for a specific domain. This endpoint requires admin access.
3829
- *
3830
- * Updating the team ID will transfer ownership and access control of the domain
3831
- * and all its DNS records to the new team.
3832
- *
3833
- * @param {string} params.domainId - Domain unique ID.
3834
- * @param {string} params.teamId - New team unique ID.
3835
- * @throws {AppwriteException}
3836
- * @returns {Promise<Models.Domain>}
3837
- */
3838
- updateTeam(params: { domainId: string, teamId: string }): Promise<Models.Domain>;
3839
- /**
3840
- * Update the team ID for a specific domain. This endpoint requires admin access.
3841
- *
3842
- * Updating the team ID will transfer ownership and access control of the domain
3843
- * and all its DNS records to the new team.
3844
- *
3845
- * @param {string} domainId - Domain unique ID.
3846
- * @param {string} teamId - New team unique ID.
3847
- * @throws {AppwriteException}
3848
- * @returns {Promise<Models.Domain>}
3849
- * @deprecated Use the object parameter style method for a better developer experience.
3850
- */
3851
- updateTeam(domainId: string, teamId: string): Promise<Models.Domain>;
3852
- updateTeam(
3853
- paramsOrFirst: { domainId: string, teamId: string } | string,
3854
- ...rest: [(string)?]
3855
- ): Promise<Models.Domain> {
3856
- let params: { domainId: string, teamId: string };
3857
-
3858
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3859
- params = (paramsOrFirst || {}) as { domainId: string, teamId: string };
3860
- } else {
3861
- params = {
3862
- domainId: paramsOrFirst as string,
3863
- teamId: rest[0] as string
3864
- };
3865
- }
3866
-
3867
- const domainId = params.domainId;
3868
- const teamId = params.teamId;
3869
-
3870
- if (typeof domainId === 'undefined') {
3871
- throw new AppwriteException('Missing required parameter: "domainId"');
3872
- }
3873
- if (typeof teamId === 'undefined') {
3874
- throw new AppwriteException('Missing required parameter: "teamId"');
3875
- }
3876
-
3877
- const apiPath = '/domains/{domainId}/team'.replace('{domainId}', domainId);
3878
- const payload: Payload = {};
3879
- if (typeof teamId !== 'undefined') {
3880
- payload['teamId'] = teamId;
3881
- }
3882
- const uri = new URL(this.client.config.endpoint + apiPath);
3883
-
3884
- const apiHeaders: { [header: string]: string } = {
3885
- 'content-type': 'application/json',
3886
- }
3887
-
3888
- return this.client.call(
3889
- 'patch',
3890
- uri,
3891
- apiHeaders,
3892
- payload
3893
- );
3894
- }
3895
-
3896
- /**
3897
- * Retrieve the current transfer status for a domain. Returns the status, an optional reason, and a timestamp of the last status change.
3898
- *
3899
- * @param {string} params.domainId - Domain unique ID.
3900
- * @throws {AppwriteException}
3901
- * @returns {Promise<Models.DomainTransferStatus>}
3902
- */
3903
- getTransferStatus(params: { domainId: string }): Promise<Models.DomainTransferStatus>;
3904
- /**
3905
- * Retrieve the current transfer status for a domain. Returns the status, an optional reason, and a timestamp of the last status change.
3906
- *
3907
- * @param {string} domainId - Domain unique ID.
3908
- * @throws {AppwriteException}
3909
- * @returns {Promise<Models.DomainTransferStatus>}
3910
- * @deprecated Use the object parameter style method for a better developer experience.
3911
- */
3912
- getTransferStatus(domainId: string): Promise<Models.DomainTransferStatus>;
3913
- getTransferStatus(
3914
- paramsOrFirst: { domainId: string } | string
3915
- ): Promise<Models.DomainTransferStatus> {
3916
- let params: { domainId: string };
3917
-
3918
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3919
- params = (paramsOrFirst || {}) as { domainId: string };
3920
- } else {
3921
- params = {
3922
- domainId: paramsOrFirst as string
3923
- };
3924
- }
3925
-
3926
- const domainId = params.domainId;
3927
-
3928
- if (typeof domainId === 'undefined') {
3929
- throw new AppwriteException('Missing required parameter: "domainId"');
3930
- }
3931
-
3932
- const apiPath = '/domains/{domainId}/transfers/status'.replace('{domainId}', domainId);
3933
- const payload: Payload = {};
3934
- const uri = new URL(this.client.config.endpoint + apiPath);
3935
-
3936
- const apiHeaders: { [header: string]: string } = {
3937
- }
3938
-
3939
- return this.client.call(
3940
- 'get',
3941
- uri,
3942
- apiHeaders,
3943
- payload
3944
- );
3945
- }
3946
-
3947
- /**
3948
- * Retrieve the DNS zone file for the given domain. This endpoint will return the DNS
3949
- * zone file in a standardized format that can be used to configure DNS servers.
3950
- *
3951
- * @param {string} params.domainId - Domain unique ID.
3952
- * @throws {AppwriteException}
3953
- * @returns {Promise<{}>}
3954
- */
3955
- getZone(params: { domainId: string }): Promise<{}>;
3956
- /**
3957
- * Retrieve the DNS zone file for the given domain. This endpoint will return the DNS
3958
- * zone file in a standardized format that can be used to configure DNS servers.
3959
- *
3960
- * @param {string} domainId - Domain unique ID.
3961
- * @throws {AppwriteException}
3962
- * @returns {Promise<{}>}
3963
- * @deprecated Use the object parameter style method for a better developer experience.
3964
- */
3965
- getZone(domainId: string): Promise<{}>;
3966
- getZone(
3967
- paramsOrFirst: { domainId: string } | string
3968
- ): Promise<{}> {
3969
- let params: { domainId: string };
3970
-
3971
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
3972
- params = (paramsOrFirst || {}) as { domainId: string };
3973
- } else {
3974
- params = {
3975
- domainId: paramsOrFirst as string
3976
- };
3977
- }
3978
-
3979
- const domainId = params.domainId;
3980
-
3981
- if (typeof domainId === 'undefined') {
3982
- throw new AppwriteException('Missing required parameter: "domainId"');
3983
- }
3984
-
3985
- const apiPath = '/domains/{domainId}/zone'.replace('{domainId}', domainId);
3986
- const payload: Payload = {};
3987
- const uri = new URL(this.client.config.endpoint + apiPath);
3988
-
3989
- const apiHeaders: { [header: string]: string } = {
3990
- }
3991
-
3992
- return this.client.call(
3993
- 'get',
3994
- uri,
3995
- apiHeaders,
3996
- payload
3997
- );
3998
- }
3999
-
4000
- /**
4001
- * Update the DNS zone for the given domain using the provided zone file content.
4002
- * All parsed records are imported and then the main domain document is returned.
4003
- *
4004
- * @param {string} params.domainId - Domain unique ID.
4005
- * @param {string} params.content - DNS zone file content as a string.
4006
- * @throws {AppwriteException}
4007
- * @returns {Promise<Models.Domain>}
4008
- */
4009
- updateZone(params: { domainId: string, content: string }): Promise<Models.Domain>;
4010
- /**
4011
- * Update the DNS zone for the given domain using the provided zone file content.
4012
- * All parsed records are imported and then the main domain document is returned.
4013
- *
4014
- * @param {string} domainId - Domain unique ID.
4015
- * @param {string} content - DNS zone file content as a string.
4016
- * @throws {AppwriteException}
4017
- * @returns {Promise<Models.Domain>}
4018
- * @deprecated Use the object parameter style method for a better developer experience.
4019
- */
4020
- updateZone(domainId: string, content: string): Promise<Models.Domain>;
4021
- updateZone(
4022
- paramsOrFirst: { domainId: string, content: string } | string,
4023
- ...rest: [(string)?]
4024
- ): Promise<Models.Domain> {
4025
- let params: { domainId: string, content: string };
4026
-
4027
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
4028
- params = (paramsOrFirst || {}) as { domainId: string, content: string };
4029
- } else {
4030
- params = {
4031
- domainId: paramsOrFirst as string,
4032
- content: rest[0] as string
4033
- };
4034
- }
4035
-
4036
- const domainId = params.domainId;
4037
- const content = params.content;
4038
-
4039
- if (typeof domainId === 'undefined') {
4040
- throw new AppwriteException('Missing required parameter: "domainId"');
4041
- }
4042
- if (typeof content === 'undefined') {
4043
- throw new AppwriteException('Missing required parameter: "content"');
4044
- }
4045
-
4046
- const apiPath = '/domains/{domainId}/zone'.replace('{domainId}', domainId);
4047
- const payload: Payload = {};
4048
- if (typeof content !== 'undefined') {
4049
- payload['content'] = content;
4050
- }
4051
- const uri = new URL(this.client.config.endpoint + apiPath);
4052
-
4053
- const apiHeaders: { [header: string]: string } = {
4054
- 'content-type': 'application/json',
4055
- }
4056
-
4057
- return this.client.call(
4058
- 'put',
4059
- uri,
4060
- apiHeaders,
4061
- payload
4062
- );
4063
- }
4064
- }