diff --git a/app/config/platforms.php b/app/config/platforms.php index 525e278cd1..280ffc30a6 100644 --- a/app/config/platforms.php +++ b/app/config/platforms.php @@ -207,7 +207,7 @@ return [ [ 'key' => 'web', 'name' => 'Console', - 'version' => '', + 'version' => '0.1.0', 'url' => '', 'package' => '', 'enabled' => true, diff --git a/app/config/specs/open-api3-1.7.x-client.json b/app/config/specs/open-api3-1.7.x-client.json index 3cf675c5ad..6813c71f74 100644 --- a/app/config/specs/open-api3-1.7.x-client.json +++ b/app/config/specs/open-api3-1.7.x-client.json @@ -5361,7 +5361,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -8033,7 +8033,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -8065,7 +8066,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -8089,7 +8096,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "sessionList": { "description": "Sessions List", @@ -8113,7 +8124,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -8137,7 +8152,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -8161,7 +8180,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -8185,7 +8208,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "teamList": { "description": "Teams List", @@ -8209,7 +8236,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -8233,7 +8264,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "executionList": { "description": "Executions List", @@ -8257,7 +8292,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -8281,7 +8320,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -8305,7 +8348,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -8329,7 +8376,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -8353,7 +8404,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -8377,7 +8432,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -8401,7 +8460,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "document": { "description": "Document", @@ -8458,7 +8521,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -8592,7 +8671,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -8753,7 +8855,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -8767,7 +8895,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -8781,7 +8912,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -8795,7 +8929,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -8809,7 +8946,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -8851,7 +8991,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -8883,7 +9030,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -8918,12 +9071,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -9110,7 +9274,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -9178,7 +9375,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -9222,7 +9431,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -9236,7 +9453,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -9286,7 +9506,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -9306,7 +9535,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -9388,7 +9621,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "team": { "description": "Team", @@ -9439,7 +9687,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -9530,7 +9789,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "execution": { "description": "Execution", @@ -9661,7 +9937,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "country": { "description": "Country", @@ -9681,7 +9986,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -9701,7 +10010,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -9727,7 +10040,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -9779,7 +10097,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -9805,7 +10132,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "headers": { "description": "Headers", @@ -9825,7 +10157,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -9857,7 +10193,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -9877,7 +10219,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -9897,7 +10245,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -9929,7 +10281,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "subscriber": { "description": "Subscriber", @@ -10003,7 +10361,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -10065,7 +10443,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "securitySchemes": { diff --git a/app/config/specs/open-api3-1.7.x-console.json b/app/config/specs/open-api3-1.7.x-console.json index 0bfebf37b9..358b282600 100644 --- a/app/config/specs/open-api3-1.7.x-console.json +++ b/app/config/specs/open-api3-1.7.x-console.json @@ -11820,7 +11820,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -35466,7 +35466,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -35498,7 +35499,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -35522,7 +35529,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -35546,7 +35557,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -35570,7 +35585,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -35594,7 +35613,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -35618,7 +35641,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -35642,7 +35669,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -35666,7 +35697,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -35690,7 +35725,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -35714,7 +35753,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -35738,7 +35781,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -35762,7 +35809,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -35786,7 +35837,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -35810,7 +35865,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -35834,7 +35893,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "templateSiteList": { "description": "Site Templates List", @@ -35858,7 +35921,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "functionList": { "description": "Functions List", @@ -35882,7 +35949,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "templateFunctionList": { "description": "Function Templates List", @@ -35906,7 +35977,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "installationList": { "description": "Installations List", @@ -35930,7 +36005,11 @@ "required": [ "total", "installations" - ] + ], + "example": { + "total": 5, + "installations": "" + } }, "providerRepositoryFrameworkList": { "description": "Framework Provider Repositories List", @@ -35954,7 +36033,11 @@ "required": [ "total", "frameworkProviderRepositories" - ] + ], + "example": { + "total": 5, + "frameworkProviderRepositories": "" + } }, "providerRepositoryRuntimeList": { "description": "Runtime Provider Repositories List", @@ -35978,7 +36061,11 @@ "required": [ "total", "runtimeProviderRepositories" - ] + ], + "example": { + "total": 5, + "runtimeProviderRepositories": "" + } }, "branchList": { "description": "Branches List", @@ -36002,7 +36089,11 @@ "required": [ "total", "branches" - ] + ], + "example": { + "total": 5, + "branches": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -36026,7 +36117,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -36050,7 +36145,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -36074,7 +36173,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -36098,7 +36201,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "projectList": { "description": "Projects List", @@ -36122,7 +36229,11 @@ "required": [ "total", "projects" - ] + ], + "example": { + "total": 5, + "projects": "" + } }, "webhookList": { "description": "Webhooks List", @@ -36146,7 +36257,11 @@ "required": [ "total", "webhooks" - ] + ], + "example": { + "total": 5, + "webhooks": "" + } }, "keyList": { "description": "API Keys List", @@ -36170,7 +36285,11 @@ "required": [ "total", "keys" - ] + ], + "example": { + "total": 5, + "keys": "" + } }, "devKeyList": { "description": "Dev Keys List", @@ -36194,7 +36313,11 @@ "required": [ "total", "devKeys" - ] + ], + "example": { + "total": 5, + "devKeys": "" + } }, "platformList": { "description": "Platforms List", @@ -36218,7 +36341,11 @@ "required": [ "total", "platforms" - ] + ], + "example": { + "total": 5, + "platforms": "" + } }, "countryList": { "description": "Countries List", @@ -36242,7 +36369,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -36266,7 +36397,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -36290,7 +36425,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -36314,7 +36453,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -36338,7 +36481,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -36362,7 +36509,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "proxyRuleList": { "description": "Rule List", @@ -36386,7 +36537,11 @@ "required": [ "total", "rules" - ] + ], + "example": { + "total": 5, + "rules": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -36410,7 +36565,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -36434,7 +36593,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -36458,7 +36621,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -36482,7 +36649,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -36506,7 +36677,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -36530,7 +36705,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "migrationList": { "description": "Migrations List", @@ -36554,7 +36733,11 @@ "required": [ "total", "migrations" - ] + ], + "example": { + "total": 5, + "migrations": "" + } }, "specificationList": { "description": "Specifications List", @@ -36578,7 +36761,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "vcsContentList": { "description": "VCS Content List", @@ -36602,7 +36789,11 @@ "required": [ "total", "contents" - ] + ], + "example": { + "total": 5, + "contents": "" + } }, "database": { "description": "Database", @@ -36640,7 +36831,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -36750,7 +36948,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -36805,7 +37017,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -36880,7 +37096,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -36957,7 +37186,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -37034,7 +37276,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -37096,7 +37351,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -37164,7 +37430,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -37241,7 +37519,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -37309,7 +37600,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -37377,7 +37680,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -37445,7 +37760,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -37537,7 +37864,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -37609,7 +37952,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -37666,7 +38020,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -37800,7 +38170,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -37961,7 +38354,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -37975,7 +38394,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -37989,7 +38411,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -38003,7 +38428,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -38017,7 +38445,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -38059,7 +38490,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -38091,7 +38529,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -38126,12 +38570,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -38318,7 +38773,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -38386,7 +38874,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -38430,7 +38930,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -38444,7 +38952,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -38494,7 +39005,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -38514,7 +39034,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -38596,7 +39120,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -38688,7 +39227,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -38738,7 +39296,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -38789,7 +39356,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -38880,7 +39458,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -39066,7 +39661,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "templateSite": { "description": "Template Site", @@ -39161,7 +39787,22 @@ "providerOwner", "providerVersion", "variables" - ] + ], + "example": { + "key": "starter", + "name": "Starter site", + "tagline": "Minimal web app integrating with Appwrite.", + "demoUrl": "https:\/\/nextjs-starter.appwrite.network\/", + "screenshotDark": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-dark.png", + "screenshotLight": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-light.png", + "useCases": "Starter", + "frameworks": [], + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [] + } }, "templateFramework": { "description": "Template Framework", @@ -39223,7 +39864,18 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/build", + "providerRootDirectory": ".\/svelte-kit\/starter", + "buildRuntime": "node-22", + "adapter": "ssr", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -39412,7 +40064,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "templateFunction": { "description": "Template Function", @@ -39541,7 +40223,26 @@ "providerVersion", "variables", "scopes" - ] + ], + "example": { + "icon": "icon-lightning-bolt", + "id": "starter", + "name": "Starter function", + "tagline": "A simple function to get started.", + "permissions": "any", + "events": "account.create", + "cron": "0 0 * * *", + "timeout": 300, + "useCases": "Starter", + "runtimes": [], + "instructions": "For documentation and instructions check out .", + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [], + "scopes": "users.read" + } }, "templateRuntime": { "description": "Template Runtime", @@ -39573,7 +40274,13 @@ "commands", "entrypoint", "providerRootDirectory" - ] + ], + "example": { + "name": "node-19.0", + "commands": "npm install", + "entrypoint": "index.js", + "providerRootDirectory": "node\/starter" + } }, "templateVariable": { "description": "Template Variable", @@ -39623,7 +40330,16 @@ "placeholder", "required", "type" - ] + ], + "example": { + "name": "APPWRITE_DATABASE_ID", + "description": "The ID of the Appwrite database that contains the collection to sync.", + "value": "512", + "secret": false, + "placeholder": "64a55...7b912", + "required": false, + "type": "password" + } }, "installation": { "description": "Installation", @@ -39667,7 +40383,15 @@ "provider", "organization", "providerInstallationId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "provider": "github", + "organization": "appwrite", + "providerInstallationId": "5322" + } }, "providerRepository": { "description": "ProviderRepository", @@ -39698,6 +40422,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39710,8 +40439,18 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime" + } }, "providerRepositoryFramework": { "description": "ProviderRepositoryFramework", @@ -39742,6 +40481,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39759,9 +40503,20 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt", "framework" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "framework": "nextjs" + } }, "providerRepositoryRuntime": { "description": "ProviderRepositoryRuntime", @@ -39792,6 +40547,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39809,9 +40569,20 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt", "runtime" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "runtime": "node-22" + } }, "detectionFramework": { "description": "DetectionFramework", @@ -39843,7 +40614,13 @@ "installCommand", "buildCommand", "outputDirectory" - ] + ], + "example": { + "framework": "nuxt", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "dist" + } }, "detectionRuntime": { "description": "DetectionRuntime", @@ -39869,7 +40646,12 @@ "runtime", "entrypoint", "commands" - ] + ], + "example": { + "runtime": "node", + "entrypoint": "index.js", + "commands": "npm install && npm run build" + } }, "vcsContent": { "description": "VcsContents", @@ -39896,7 +40678,12 @@ }, "required": [ "name" - ] + ], + "example": { + "size": 1523, + "isDirectory": true, + "name": "Main.java" + } }, "branch": { "description": "Branch", @@ -39910,7 +40697,10 @@ }, "required": [ "name" - ] + ], + "example": { + "name": "main" + } }, "runtime": { "description": "Runtime", @@ -39969,7 +40759,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -40024,7 +40824,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -40062,7 +40880,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -40236,7 +41061,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -40367,7 +41221,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "project": { "description": "Project", @@ -40763,7 +41646,73 @@ "serviceStatusForFunctions", "serviceStatusForGraphql", "serviceStatusForMessaging" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "New Project", + "description": "This is a new project.", + "teamId": "1592981250", + "logo": "5f5c451b403cb", + "url": "5f5c451b403cb", + "legalName": "Company LTD.", + "legalCountry": "US", + "legalState": "New York", + "legalCity": "New York City.", + "legalAddress": "620 Eighth Avenue, New York, NY 10018", + "legalTaxId": "131102020", + "authDuration": 60, + "authLimit": 100, + "authSessionsLimit": 10, + "authPasswordHistory": 5, + "authPasswordDictionary": true, + "authPersonalDataCheck": true, + "authMockNumbers": [ + {} + ], + "authSessionAlerts": true, + "authMembershipsUserName": true, + "authMembershipsUserEmail": true, + "authMembershipsMfa": true, + "oAuthProviders": [ + {} + ], + "platforms": {}, + "webhooks": {}, + "keys": {}, + "devKeys": {}, + "smtpEnabled": false, + "smtpSenderName": "John Appwrite", + "smtpSenderEmail": "john@appwrite.io", + "smtpReplyTo": "support@appwrite.io", + "smtpHost": "mail.appwrite.io", + "smtpPort": 25, + "smtpUsername": "emailuser", + "smtpPassword": "securepassword", + "smtpSecure": "tls", + "pingCount": 1, + "pingedAt": "2020-10-15T06:38:00.000+00:00", + "authEmailPassword": true, + "authUsersAuthMagicURL": true, + "authEmailOtp": true, + "authAnonymous": true, + "authInvites": true, + "authJWT": true, + "authPhone": true, + "serviceStatusForAccount": true, + "serviceStatusForAvatars": true, + "serviceStatusForDatabases": true, + "serviceStatusForLocale": true, + "serviceStatusForHealth": true, + "serviceStatusForStorage": true, + "serviceStatusForTeams": true, + "serviceStatusForUsers": true, + "serviceStatusForSites": true, + "serviceStatusForFunctions": true, + "serviceStatusForGraphql": true, + "serviceStatusForMessaging": true + } }, "webhook": { "description": "Webhook", @@ -40853,7 +41802,22 @@ "enabled", "logs", "attempts" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Webhook", + "url": "https:\/\/example.com\/webhook", + "events": "database.collections.update", + "security": true, + "httpUser": "username", + "httpPass": "password", + "signatureKey": "ad3d581ca230e2b7059c545e5a", + "enabled": true, + "logs": "Failed to connect to remote server.", + "attempts": 10 + } }, "key": { "description": "Key", @@ -40921,7 +41885,18 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "scopes": "users.read", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "devKey": { "description": "DevKey", @@ -40980,7 +41955,17 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Dev API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "mockNumber": { "description": "Mock Number", @@ -41000,7 +41985,11 @@ "required": [ "phone", "otp" - ] + ], + "example": { + "phone": "+1612842323", + "otp": "123456" + } }, "authProvider": { "description": "AuthProvider", @@ -41038,7 +42027,14 @@ "appId", "secret", "enabled" - ] + ], + "example": { + "key": "github", + "name": "GitHub", + "appId": "259125845563242502", + "secret": "Bpw_g9c2TGXxfgLshDbSaL8tsCcqgczQ", + "enabled": "" + } }, "platform": { "description": "Platform", @@ -41106,7 +42102,19 @@ "hostname", "httpUser", "httpPass" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Web App", + "type": "web", + "key": "com.company.appname", + "store": "", + "hostname": true, + "httpUser": "username", + "httpPass": "password" + } }, "variable": { "description": "Variable", @@ -41162,7 +42170,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -41182,7 +42200,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -41202,7 +42224,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -41228,7 +42254,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -41280,7 +42311,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -41306,7 +42346,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -41326,7 +42371,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -41341,7 +42390,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -41368,7 +42420,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -41412,7 +42469,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -41441,7 +42506,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "metric": { "description": "Metric", @@ -41462,7 +42532,11 @@ "required": [ "value", "date" - ] + ], + "example": { + "value": 1, + "date": "2020-10-15T06:38:00.000+00:00" + } }, "metricBreakdown": { "description": "Metric Breakdown", @@ -41496,7 +42570,13 @@ "required": [ "name", "value" - ] + ], + "example": { + "resourceId": "5e5ea5c16897e", + "name": "Documents", + "value": 1, + "estimate": 1 + } }, "usageDatabases": { "description": "UsageDatabases", @@ -41606,7 +42686,22 @@ "storage", "databasesReads", "databasesWrites" - ] + ], + "example": { + "range": "30d", + "databasesTotal": 0, + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "databases": [], + "collections": [], + "documents": [], + "storage": [], + "databasesReads": [], + "databasesWrites": [] + } }, "usageDatabase": { "description": "UsageDatabase", @@ -41700,7 +42795,20 @@ "storage", "databaseReads", "databaseWrites" - ] + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } }, "usageCollection": { "description": "UsageCollection", @@ -41730,7 +42838,12 @@ "range", "documentsTotal", "documents" - ] + ], + "example": { + "range": "30d", + "documentsTotal": 0, + "documents": [] + } }, "usageUsers": { "description": "UsageUsers", @@ -41776,7 +42889,14 @@ "sessionsTotal", "users", "sessions" - ] + ], + "example": { + "range": "30d", + "usersTotal": 0, + "sessionsTotal": 0, + "users": [], + "sessions": [] + } }, "usageStorage": { "description": "StorageUsage", @@ -41838,7 +42958,16 @@ "buckets", "files", "storage" - ] + ], + "example": { + "range": "30d", + "bucketsTotal": 0, + "filesTotal": 0, + "filesStorageTotal": 0, + "buckets": [], + "files": [], + "storage": [] + } }, "usageBuckets": { "description": "UsageBuckets", @@ -41900,7 +43029,16 @@ "storage", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "range": "30d", + "filesTotal": 0, + "filesStorageTotal": 0, + "files": [], + "storage": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "usageFunctions": { "description": "UsageFunctions", @@ -42106,7 +43244,34 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "functionsTotal": 0, + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "functions": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageFunction": { "description": "UsageFunction", @@ -42303,7 +43468,33 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageSites": { "description": "UsageSites", @@ -42557,7 +43748,40 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "sitesTotal": 0, + "sites": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageSite": { "description": "UsageSite", @@ -42802,7 +44026,39 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageProject": { "description": "UsageProject", @@ -43055,7 +44311,40 @@ "databasesWrites", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "executionsTotal": 0, + "documentsTotal": 0, + "databasesTotal": 0, + "databasesStorageTotal": 0, + "usersTotal": 0, + "filesStorageTotal": 0, + "functionsStorageTotal": 0, + "buildsStorageTotal": 0, + "deploymentsStorageTotal": 0, + "bucketsTotal": 0, + "executionsMbSecondsTotal": 0, + "buildsMbSecondsTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "requests": [], + "network": [], + "users": [], + "executions": [], + "executionsBreakdown": [], + "bucketsBreakdown": [], + "databasesStorageBreakdown": [], + "executionsMbSecondsBreakdown": [], + "buildsMbSecondsBreakdown": [], + "functionsStorageBreakdown": [], + "authPhoneTotal": 0, + "authPhoneEstimate": 0, + "authPhoneCountryBreakdown": [], + "databasesReads": [], + "databasesWrites": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "headers": { "description": "Headers", @@ -43075,7 +44364,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -43109,7 +44402,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "proxyRule": { "description": "Rule", @@ -43208,7 +44507,24 @@ "status", "logs", "renewAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "domain": "appwrite.company.com", + "type": "deployment", + "trigger": "manual", + "redirectUrl": "https:\/\/appwrite.io\/docs", + "redirectStatusCode": 301, + "deploymentId": "n3u9feiwmf", + "deploymentResourceType": "function", + "deploymentResourceId": "n3u9feiwmf", + "deploymentVcsProviderBranch": "function", + "status": "verified", + "logs": "HTTP challegne failed.", + "renewAt": "datetime" + } }, "smsTemplate": { "description": "SmsTemplate", @@ -43234,7 +44550,12 @@ "type", "locale", "message" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account." + } }, "emailTemplate": { "description": "EmailTemplate", @@ -43284,7 +44605,16 @@ "senderEmail", "replyTo", "subject" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account.", + "senderName": "My User", + "senderEmail": "mail@appwrite.io", + "replyTo": "emails@appwrite.io", + "subject": "Please verify your email address" + } }, "consoleVariables": { "description": "Console Variables", @@ -43372,7 +44702,22 @@ "_APP_DOMAIN_FUNCTIONS", "_APP_OPTIONS_FORCE_HTTPS", "_APP_DOMAINS_NAMESERVERS" - ] + ], + "example": { + "_APP_DOMAIN_TARGET_CNAME": "appwrite.io", + "_APP_DOMAIN_TARGET_A": "127.0.0.1", + "_APP_DOMAIN_TARGET_AAAA": "::1", + "_APP_STORAGE_LIMIT": "30000000", + "_APP_COMPUTE_SIZE_LIMIT": "30000000", + "_APP_USAGE_STATS": "enabled", + "_APP_VCS_ENABLED": true, + "_APP_DOMAIN_ENABLED": true, + "_APP_ASSISTANT_ENABLED": true, + "_APP_DOMAIN_SITES": "sites.localhost", + "_APP_DOMAIN_FUNCTIONS": "functions.localhost", + "_APP_OPTIONS_FORCE_HTTPS": "enabled", + "_APP_DOMAINS_NAMESERVERS": "ns1.example.com,ns2.example.com" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -43404,7 +44749,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -43424,7 +44775,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -43444,7 +44801,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -43476,7 +44837,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -43542,7 +44909,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -43652,7 +45034,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -43714,7 +45122,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -43788,7 +45206,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -43850,7 +45288,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } }, "migration": { "description": "Migration", @@ -43938,7 +45387,23 @@ "statusCounters", "resourceData", "errors" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "status": "pending", + "stage": "init", + "source": "Appwrite", + "destination": "Appwrite", + "resources": [ + "user" + ], + "resourceId": "databaseId:collectionId", + "statusCounters": "{\"Database\": {\"PENDING\": 0, \"SUCCESS\": 1, \"ERROR\": 0, \"SKIP\": 0, \"PROCESSING\": 0, \"WARNING\": 0}}", + "resourceData": "[{\"resource\":\"Database\",\"id\":\"public\",\"status\":\"SUCCESS\",\"message\":\"\"}]", + "errors": [] + } }, "migrationReport": { "description": "Migration Report", @@ -44008,7 +45473,18 @@ "function", "size", "version" - ] + ], + "example": { + "user": 20, + "team": 20, + "database": 20, + "document": 20, + "file": 20, + "bucket": 20, + "function": 20, + "size": 30000, + "version": "1.4.0" + } } }, "securitySchemes": { diff --git a/app/config/specs/open-api3-1.7.x-server.json b/app/config/specs/open-api3-1.7.x-server.json index bd78f99a76..35a1066924 100644 --- a/app/config/specs/open-api3-1.7.x-server.json +++ b/app/config/specs/open-api3-1.7.x-server.json @@ -10690,7 +10690,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -25744,7 +25744,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -25776,7 +25777,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -25800,7 +25807,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -25824,7 +25835,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -25848,7 +25863,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -25872,7 +25891,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -25896,7 +25919,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -25920,7 +25947,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -25944,7 +25975,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -25968,7 +26003,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -25992,7 +26031,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -26016,7 +26059,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -26040,7 +26087,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -26064,7 +26115,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -26088,7 +26143,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -26112,7 +26171,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "functionList": { "description": "Functions List", @@ -26136,7 +26199,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -26160,7 +26227,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -26184,7 +26255,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -26208,7 +26283,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -26232,7 +26311,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -26256,7 +26339,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -26280,7 +26367,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -26304,7 +26395,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -26328,7 +26423,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -26352,7 +26451,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -26376,7 +26479,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -26400,7 +26507,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -26424,7 +26535,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -26448,7 +26563,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -26472,7 +26591,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -26496,7 +26619,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -26520,7 +26647,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "specificationList": { "description": "Specifications List", @@ -26544,7 +26675,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "database": { "description": "Database", @@ -26582,7 +26717,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -26692,7 +26834,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -26747,7 +26903,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -26822,7 +26982,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -26899,7 +27072,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -26976,7 +27162,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -27038,7 +27237,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -27106,7 +27316,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -27183,7 +27405,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -27251,7 +27486,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -27319,7 +27566,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -27387,7 +27646,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -27479,7 +27750,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -27551,7 +27838,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -27608,7 +27906,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -27742,7 +28056,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -27903,7 +28240,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -27917,7 +28280,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -27931,7 +28297,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -27945,7 +28314,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -27959,7 +28331,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -28001,7 +28376,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -28033,7 +28415,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -28068,12 +28456,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -28260,7 +28659,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -28328,7 +28760,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -28372,7 +28816,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -28386,7 +28838,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -28436,7 +28891,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -28456,7 +28920,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -28538,7 +29006,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -28630,7 +29113,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -28680,7 +29182,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -28731,7 +29242,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -28822,7 +29344,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -29008,7 +29547,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -29197,7 +29767,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "runtime": { "description": "Runtime", @@ -29256,7 +29856,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -29311,7 +29921,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -29349,7 +29977,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -29523,7 +30158,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -29654,7 +30318,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "variable": { "description": "Variable", @@ -29710,7 +30403,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -29730,7 +30433,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -29750,7 +30457,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -29776,7 +30487,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -29828,7 +30544,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -29854,7 +30579,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -29874,7 +30604,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -29889,7 +30623,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -29916,7 +30653,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -29960,7 +30702,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -29989,7 +30739,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "headers": { "description": "Headers", @@ -30009,7 +30764,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -30043,7 +30802,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -30075,7 +30840,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -30095,7 +30866,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -30115,7 +30892,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -30147,7 +30928,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -30213,7 +31000,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -30323,7 +31125,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -30385,7 +31213,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -30459,7 +31297,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -30521,7 +31379,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "securitySchemes": { diff --git a/app/config/specs/open-api3-latest-client.json b/app/config/specs/open-api3-latest-client.json index 1364e2e053..6813c71f74 100644 --- a/app/config/specs/open-api3-latest-client.json +++ b/app/config/specs/open-api3-latest-client.json @@ -4489,30 +4489,6 @@ } ], "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection) API or directly from your database console." - }, - { - "name": "createDocuments", - "auth": { - "Admin": [], - "Key": [] - }, - "parameters": [ - "databaseId", - "collectionId", - "documents" - ], - "required": [ - "databaseId", - "collectionId", - "documents" - ], - "responses": [ - { - "code": 201, - "model": "#\/components\/schemas\/documentList" - } - ], - "description": "**WARNING: Experimental Feature** - This endpoint is experimental and not yet officially supported. It may be subject to breaking changes or removal in future versions.\n\nCreate new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection) API or directly from your database console." } ], "auth": { @@ -5385,7 +5361,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -8057,7 +8033,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -8089,7 +8066,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -8113,7 +8096,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "sessionList": { "description": "Sessions List", @@ -8137,7 +8124,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -8161,7 +8152,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -8185,7 +8180,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -8209,7 +8208,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "teamList": { "description": "Teams List", @@ -8233,7 +8236,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -8257,7 +8264,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "executionList": { "description": "Executions List", @@ -8281,7 +8292,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -8305,7 +8320,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -8329,7 +8348,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -8353,7 +8376,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -8377,7 +8404,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -8401,7 +8432,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -8425,7 +8460,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "document": { "description": "Document", @@ -8482,7 +8521,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -8616,7 +8671,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -8777,7 +8855,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -8791,7 +8895,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -8805,7 +8912,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -8819,7 +8929,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -8833,7 +8946,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -8875,7 +8991,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -8907,7 +9030,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -8942,12 +9071,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -9134,7 +9274,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -9202,7 +9375,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -9246,7 +9431,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -9260,7 +9453,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -9310,7 +9506,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -9330,7 +9535,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -9412,7 +9621,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "team": { "description": "Team", @@ -9463,7 +9687,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -9554,7 +9789,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "execution": { "description": "Execution", @@ -9685,7 +9937,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "country": { "description": "Country", @@ -9705,7 +9986,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -9725,7 +10010,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -9751,7 +10040,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -9803,7 +10097,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -9829,7 +10132,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "headers": { "description": "Headers", @@ -9849,7 +10157,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -9881,7 +10193,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -9901,7 +10219,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -9921,7 +10245,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -9953,7 +10281,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "subscriber": { "description": "Subscriber", @@ -10027,7 +10361,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -10089,7 +10443,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "securitySchemes": { diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index cfce70b45b..358b282600 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -11820,7 +11820,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -35466,7 +35466,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -35498,7 +35499,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -35522,7 +35529,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -35546,7 +35557,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -35570,7 +35585,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -35594,7 +35613,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -35618,7 +35641,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -35642,7 +35669,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -35666,7 +35697,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -35690,7 +35725,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -35714,7 +35753,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -35738,7 +35781,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -35762,7 +35809,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -35786,7 +35837,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -35810,7 +35865,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -35834,7 +35893,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "templateSiteList": { "description": "Site Templates List", @@ -35858,7 +35921,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "functionList": { "description": "Functions List", @@ -35882,7 +35949,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "templateFunctionList": { "description": "Function Templates List", @@ -35906,7 +35977,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "installationList": { "description": "Installations List", @@ -35930,7 +36005,11 @@ "required": [ "total", "installations" - ] + ], + "example": { + "total": 5, + "installations": "" + } }, "providerRepositoryFrameworkList": { "description": "Framework Provider Repositories List", @@ -35954,7 +36033,11 @@ "required": [ "total", "frameworkProviderRepositories" - ] + ], + "example": { + "total": 5, + "frameworkProviderRepositories": "" + } }, "providerRepositoryRuntimeList": { "description": "Runtime Provider Repositories List", @@ -35978,7 +36061,11 @@ "required": [ "total", "runtimeProviderRepositories" - ] + ], + "example": { + "total": 5, + "runtimeProviderRepositories": "" + } }, "branchList": { "description": "Branches List", @@ -36002,7 +36089,11 @@ "required": [ "total", "branches" - ] + ], + "example": { + "total": 5, + "branches": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -36026,7 +36117,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -36050,7 +36145,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -36074,7 +36173,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -36098,7 +36201,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "projectList": { "description": "Projects List", @@ -36122,7 +36229,11 @@ "required": [ "total", "projects" - ] + ], + "example": { + "total": 5, + "projects": "" + } }, "webhookList": { "description": "Webhooks List", @@ -36146,7 +36257,11 @@ "required": [ "total", "webhooks" - ] + ], + "example": { + "total": 5, + "webhooks": "" + } }, "keyList": { "description": "API Keys List", @@ -36170,7 +36285,11 @@ "required": [ "total", "keys" - ] + ], + "example": { + "total": 5, + "keys": "" + } }, "devKeyList": { "description": "Dev Keys List", @@ -36194,7 +36313,11 @@ "required": [ "total", "devKeys" - ] + ], + "example": { + "total": 5, + "devKeys": "" + } }, "platformList": { "description": "Platforms List", @@ -36218,7 +36341,11 @@ "required": [ "total", "platforms" - ] + ], + "example": { + "total": 5, + "platforms": "" + } }, "countryList": { "description": "Countries List", @@ -36242,7 +36369,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -36266,7 +36397,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -36290,7 +36425,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -36314,7 +36453,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -36338,7 +36481,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -36362,7 +36509,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "proxyRuleList": { "description": "Rule List", @@ -36386,7 +36537,11 @@ "required": [ "total", "rules" - ] + ], + "example": { + "total": 5, + "rules": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -36410,7 +36565,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -36434,7 +36593,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -36458,7 +36621,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -36482,7 +36649,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -36506,7 +36677,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -36530,7 +36705,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "migrationList": { "description": "Migrations List", @@ -36554,7 +36733,11 @@ "required": [ "total", "migrations" - ] + ], + "example": { + "total": 5, + "migrations": "" + } }, "specificationList": { "description": "Specifications List", @@ -36578,7 +36761,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "vcsContentList": { "description": "VCS Content List", @@ -36602,7 +36789,11 @@ "required": [ "total", "contents" - ] + ], + "example": { + "total": 5, + "contents": "" + } }, "database": { "description": "Database", @@ -36640,7 +36831,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -36750,7 +36948,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -36805,7 +37017,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -36880,7 +37096,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -36957,7 +37186,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -37034,7 +37276,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -37096,7 +37351,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -37164,7 +37430,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -37241,7 +37519,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -37309,7 +37600,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -37377,7 +37680,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -37445,7 +37760,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -37537,7 +37864,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -37609,7 +37952,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -37666,7 +38020,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -37800,7 +38170,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -37961,7 +38354,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -37975,7 +38394,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -37989,7 +38411,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -38003,7 +38428,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -38017,7 +38445,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -38059,7 +38490,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -38091,7 +38529,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -38126,12 +38570,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -38318,7 +38773,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -38386,7 +38874,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -38430,7 +38930,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -38444,7 +38952,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -38494,7 +39005,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -38514,7 +39034,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -38596,7 +39120,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -38688,7 +39227,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -38738,7 +39296,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -38789,7 +39356,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -38880,7 +39458,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -39066,7 +39661,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "templateSite": { "description": "Template Site", @@ -39161,7 +39787,22 @@ "providerOwner", "providerVersion", "variables" - ] + ], + "example": { + "key": "starter", + "name": "Starter site", + "tagline": "Minimal web app integrating with Appwrite.", + "demoUrl": "https:\/\/nextjs-starter.appwrite.network\/", + "screenshotDark": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-dark.png", + "screenshotLight": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-light.png", + "useCases": "Starter", + "frameworks": [], + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [] + } }, "templateFramework": { "description": "Template Framework", @@ -39223,7 +39864,18 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/build", + "providerRootDirectory": ".\/svelte-kit\/starter", + "buildRuntime": "node-22", + "adapter": "ssr", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -39412,7 +40064,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "templateFunction": { "description": "Template Function", @@ -39541,7 +40223,26 @@ "providerVersion", "variables", "scopes" - ] + ], + "example": { + "icon": "icon-lightning-bolt", + "id": "starter", + "name": "Starter function", + "tagline": "A simple function to get started.", + "permissions": "any", + "events": "account.create", + "cron": "0 0 * * *", + "timeout": 300, + "useCases": "Starter", + "runtimes": [], + "instructions": "For documentation and instructions check out .", + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [], + "scopes": "users.read" + } }, "templateRuntime": { "description": "Template Runtime", @@ -39573,7 +40274,13 @@ "commands", "entrypoint", "providerRootDirectory" - ] + ], + "example": { + "name": "node-19.0", + "commands": "npm install", + "entrypoint": "index.js", + "providerRootDirectory": "node\/starter" + } }, "templateVariable": { "description": "Template Variable", @@ -39623,7 +40330,16 @@ "placeholder", "required", "type" - ] + ], + "example": { + "name": "APPWRITE_DATABASE_ID", + "description": "The ID of the Appwrite database that contains the collection to sync.", + "value": "512", + "secret": false, + "placeholder": "64a55...7b912", + "required": false, + "type": "password" + } }, "installation": { "description": "Installation", @@ -39667,7 +40383,15 @@ "provider", "organization", "providerInstallationId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "provider": "github", + "organization": "appwrite", + "providerInstallationId": "5322" + } }, "providerRepository": { "description": "ProviderRepository", @@ -39717,7 +40441,16 @@ "private", "defaultBranch", "pushedAt" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime" + } }, "providerRepositoryFramework": { "description": "ProviderRepositoryFramework", @@ -39773,7 +40506,17 @@ "defaultBranch", "pushedAt", "framework" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "framework": "nextjs" + } }, "providerRepositoryRuntime": { "description": "ProviderRepositoryRuntime", @@ -39829,7 +40572,17 @@ "defaultBranch", "pushedAt", "runtime" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "runtime": "node-22" + } }, "detectionFramework": { "description": "DetectionFramework", @@ -39861,7 +40614,13 @@ "installCommand", "buildCommand", "outputDirectory" - ] + ], + "example": { + "framework": "nuxt", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "dist" + } }, "detectionRuntime": { "description": "DetectionRuntime", @@ -39887,7 +40646,12 @@ "runtime", "entrypoint", "commands" - ] + ], + "example": { + "runtime": "node", + "entrypoint": "index.js", + "commands": "npm install && npm run build" + } }, "vcsContent": { "description": "VcsContents", @@ -39914,7 +40678,12 @@ }, "required": [ "name" - ] + ], + "example": { + "size": 1523, + "isDirectory": true, + "name": "Main.java" + } }, "branch": { "description": "Branch", @@ -39928,7 +40697,10 @@ }, "required": [ "name" - ] + ], + "example": { + "name": "main" + } }, "runtime": { "description": "Runtime", @@ -39987,7 +40759,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -40042,7 +40824,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -40080,7 +40880,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -40254,7 +41061,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -40385,7 +41221,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "project": { "description": "Project", @@ -40781,7 +41646,73 @@ "serviceStatusForFunctions", "serviceStatusForGraphql", "serviceStatusForMessaging" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "New Project", + "description": "This is a new project.", + "teamId": "1592981250", + "logo": "5f5c451b403cb", + "url": "5f5c451b403cb", + "legalName": "Company LTD.", + "legalCountry": "US", + "legalState": "New York", + "legalCity": "New York City.", + "legalAddress": "620 Eighth Avenue, New York, NY 10018", + "legalTaxId": "131102020", + "authDuration": 60, + "authLimit": 100, + "authSessionsLimit": 10, + "authPasswordHistory": 5, + "authPasswordDictionary": true, + "authPersonalDataCheck": true, + "authMockNumbers": [ + {} + ], + "authSessionAlerts": true, + "authMembershipsUserName": true, + "authMembershipsUserEmail": true, + "authMembershipsMfa": true, + "oAuthProviders": [ + {} + ], + "platforms": {}, + "webhooks": {}, + "keys": {}, + "devKeys": {}, + "smtpEnabled": false, + "smtpSenderName": "John Appwrite", + "smtpSenderEmail": "john@appwrite.io", + "smtpReplyTo": "support@appwrite.io", + "smtpHost": "mail.appwrite.io", + "smtpPort": 25, + "smtpUsername": "emailuser", + "smtpPassword": "securepassword", + "smtpSecure": "tls", + "pingCount": 1, + "pingedAt": "2020-10-15T06:38:00.000+00:00", + "authEmailPassword": true, + "authUsersAuthMagicURL": true, + "authEmailOtp": true, + "authAnonymous": true, + "authInvites": true, + "authJWT": true, + "authPhone": true, + "serviceStatusForAccount": true, + "serviceStatusForAvatars": true, + "serviceStatusForDatabases": true, + "serviceStatusForLocale": true, + "serviceStatusForHealth": true, + "serviceStatusForStorage": true, + "serviceStatusForTeams": true, + "serviceStatusForUsers": true, + "serviceStatusForSites": true, + "serviceStatusForFunctions": true, + "serviceStatusForGraphql": true, + "serviceStatusForMessaging": true + } }, "webhook": { "description": "Webhook", @@ -40871,7 +41802,22 @@ "enabled", "logs", "attempts" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Webhook", + "url": "https:\/\/example.com\/webhook", + "events": "database.collections.update", + "security": true, + "httpUser": "username", + "httpPass": "password", + "signatureKey": "ad3d581ca230e2b7059c545e5a", + "enabled": true, + "logs": "Failed to connect to remote server.", + "attempts": 10 + } }, "key": { "description": "Key", @@ -40939,7 +41885,18 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "scopes": "users.read", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "devKey": { "description": "DevKey", @@ -40998,7 +41955,17 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Dev API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "mockNumber": { "description": "Mock Number", @@ -41018,7 +41985,11 @@ "required": [ "phone", "otp" - ] + ], + "example": { + "phone": "+1612842323", + "otp": "123456" + } }, "authProvider": { "description": "AuthProvider", @@ -41056,7 +42027,14 @@ "appId", "secret", "enabled" - ] + ], + "example": { + "key": "github", + "name": "GitHub", + "appId": "259125845563242502", + "secret": "Bpw_g9c2TGXxfgLshDbSaL8tsCcqgczQ", + "enabled": "" + } }, "platform": { "description": "Platform", @@ -41124,7 +42102,19 @@ "hostname", "httpUser", "httpPass" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Web App", + "type": "web", + "key": "com.company.appname", + "store": "", + "hostname": true, + "httpUser": "username", + "httpPass": "password" + } }, "variable": { "description": "Variable", @@ -41180,7 +42170,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -41200,7 +42200,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -41220,7 +42224,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -41246,7 +42254,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -41298,7 +42311,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -41324,7 +42346,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -41344,7 +42371,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -41359,7 +42390,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -41386,7 +42420,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -41430,7 +42469,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -41459,7 +42506,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "metric": { "description": "Metric", @@ -41480,7 +42532,11 @@ "required": [ "value", "date" - ] + ], + "example": { + "value": 1, + "date": "2020-10-15T06:38:00.000+00:00" + } }, "metricBreakdown": { "description": "Metric Breakdown", @@ -41514,7 +42570,13 @@ "required": [ "name", "value" - ] + ], + "example": { + "resourceId": "5e5ea5c16897e", + "name": "Documents", + "value": 1, + "estimate": 1 + } }, "usageDatabases": { "description": "UsageDatabases", @@ -41624,7 +42686,22 @@ "storage", "databasesReads", "databasesWrites" - ] + ], + "example": { + "range": "30d", + "databasesTotal": 0, + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "databases": [], + "collections": [], + "documents": [], + "storage": [], + "databasesReads": [], + "databasesWrites": [] + } }, "usageDatabase": { "description": "UsageDatabase", @@ -41718,7 +42795,20 @@ "storage", "databaseReads", "databaseWrites" - ] + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } }, "usageCollection": { "description": "UsageCollection", @@ -41748,7 +42838,12 @@ "range", "documentsTotal", "documents" - ] + ], + "example": { + "range": "30d", + "documentsTotal": 0, + "documents": [] + } }, "usageUsers": { "description": "UsageUsers", @@ -41794,7 +42889,14 @@ "sessionsTotal", "users", "sessions" - ] + ], + "example": { + "range": "30d", + "usersTotal": 0, + "sessionsTotal": 0, + "users": [], + "sessions": [] + } }, "usageStorage": { "description": "StorageUsage", @@ -41856,7 +42958,16 @@ "buckets", "files", "storage" - ] + ], + "example": { + "range": "30d", + "bucketsTotal": 0, + "filesTotal": 0, + "filesStorageTotal": 0, + "buckets": [], + "files": [], + "storage": [] + } }, "usageBuckets": { "description": "UsageBuckets", @@ -41918,7 +43029,16 @@ "storage", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "range": "30d", + "filesTotal": 0, + "filesStorageTotal": 0, + "files": [], + "storage": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "usageFunctions": { "description": "UsageFunctions", @@ -42124,7 +43244,34 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "functionsTotal": 0, + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "functions": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageFunction": { "description": "UsageFunction", @@ -42321,7 +43468,33 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageSites": { "description": "UsageSites", @@ -42575,7 +43748,40 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "sitesTotal": 0, + "sites": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageSite": { "description": "UsageSite", @@ -42820,7 +44026,39 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageProject": { "description": "UsageProject", @@ -43073,7 +44311,40 @@ "databasesWrites", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "executionsTotal": 0, + "documentsTotal": 0, + "databasesTotal": 0, + "databasesStorageTotal": 0, + "usersTotal": 0, + "filesStorageTotal": 0, + "functionsStorageTotal": 0, + "buildsStorageTotal": 0, + "deploymentsStorageTotal": 0, + "bucketsTotal": 0, + "executionsMbSecondsTotal": 0, + "buildsMbSecondsTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "requests": [], + "network": [], + "users": [], + "executions": [], + "executionsBreakdown": [], + "bucketsBreakdown": [], + "databasesStorageBreakdown": [], + "executionsMbSecondsBreakdown": [], + "buildsMbSecondsBreakdown": [], + "functionsStorageBreakdown": [], + "authPhoneTotal": 0, + "authPhoneEstimate": 0, + "authPhoneCountryBreakdown": [], + "databasesReads": [], + "databasesWrites": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "headers": { "description": "Headers", @@ -43093,7 +44364,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -43127,7 +44402,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "proxyRule": { "description": "Rule", @@ -43226,7 +44507,24 @@ "status", "logs", "renewAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "domain": "appwrite.company.com", + "type": "deployment", + "trigger": "manual", + "redirectUrl": "https:\/\/appwrite.io\/docs", + "redirectStatusCode": 301, + "deploymentId": "n3u9feiwmf", + "deploymentResourceType": "function", + "deploymentResourceId": "n3u9feiwmf", + "deploymentVcsProviderBranch": "function", + "status": "verified", + "logs": "HTTP challegne failed.", + "renewAt": "datetime" + } }, "smsTemplate": { "description": "SmsTemplate", @@ -43252,7 +44550,12 @@ "type", "locale", "message" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account." + } }, "emailTemplate": { "description": "EmailTemplate", @@ -43302,7 +44605,16 @@ "senderEmail", "replyTo", "subject" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account.", + "senderName": "My User", + "senderEmail": "mail@appwrite.io", + "replyTo": "emails@appwrite.io", + "subject": "Please verify your email address" + } }, "consoleVariables": { "description": "Console Variables", @@ -43390,7 +44702,22 @@ "_APP_DOMAIN_FUNCTIONS", "_APP_OPTIONS_FORCE_HTTPS", "_APP_DOMAINS_NAMESERVERS" - ] + ], + "example": { + "_APP_DOMAIN_TARGET_CNAME": "appwrite.io", + "_APP_DOMAIN_TARGET_A": "127.0.0.1", + "_APP_DOMAIN_TARGET_AAAA": "::1", + "_APP_STORAGE_LIMIT": "30000000", + "_APP_COMPUTE_SIZE_LIMIT": "30000000", + "_APP_USAGE_STATS": "enabled", + "_APP_VCS_ENABLED": true, + "_APP_DOMAIN_ENABLED": true, + "_APP_ASSISTANT_ENABLED": true, + "_APP_DOMAIN_SITES": "sites.localhost", + "_APP_DOMAIN_FUNCTIONS": "functions.localhost", + "_APP_OPTIONS_FORCE_HTTPS": "enabled", + "_APP_DOMAINS_NAMESERVERS": "ns1.example.com,ns2.example.com" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -43422,7 +44749,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -43442,7 +44775,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -43462,7 +44801,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -43494,7 +44837,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -43560,7 +44909,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -43670,7 +45034,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -43732,7 +45122,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -43806,7 +45206,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -43868,7 +45288,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } }, "migration": { "description": "Migration", @@ -43956,7 +45387,23 @@ "statusCounters", "resourceData", "errors" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "status": "pending", + "stage": "init", + "source": "Appwrite", + "destination": "Appwrite", + "resources": [ + "user" + ], + "resourceId": "databaseId:collectionId", + "statusCounters": "{\"Database\": {\"PENDING\": 0, \"SUCCESS\": 1, \"ERROR\": 0, \"SKIP\": 0, \"PROCESSING\": 0, \"WARNING\": 0}}", + "resourceData": "[{\"resource\":\"Database\",\"id\":\"public\",\"status\":\"SUCCESS\",\"message\":\"\"}]", + "errors": [] + } }, "migrationReport": { "description": "Migration Report", @@ -44026,7 +45473,18 @@ "function", "size", "version" - ] + ], + "example": { + "user": 20, + "team": 20, + "database": 20, + "document": 20, + "file": 20, + "bucket": 20, + "function": 20, + "size": 30000, + "version": "1.4.0" + } } }, "securitySchemes": { diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index bd78f99a76..35a1066924 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -10690,7 +10690,7 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": null + "x-example": "" } } } @@ -25744,7 +25744,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "error": { "description": "Error", @@ -25776,7 +25777,13 @@ "code", "type", "version" - ] + ], + "example": { + "message": "Not found", + "code": "404", + "type": "not_found", + "version": "1.0" + } }, "documentList": { "description": "Documents List", @@ -25800,7 +25807,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -25824,7 +25835,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -25848,7 +25863,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -25872,7 +25891,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -25896,7 +25919,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -25920,7 +25947,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -25944,7 +25975,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -25968,7 +26003,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -25992,7 +26031,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -26016,7 +26059,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -26040,7 +26087,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -26064,7 +26115,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -26088,7 +26143,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -26112,7 +26171,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "functionList": { "description": "Functions List", @@ -26136,7 +26199,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -26160,7 +26227,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -26184,7 +26255,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -26208,7 +26283,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -26232,7 +26311,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -26256,7 +26339,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -26280,7 +26367,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -26304,7 +26395,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -26328,7 +26423,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -26352,7 +26451,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -26376,7 +26479,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -26400,7 +26507,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -26424,7 +26535,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -26448,7 +26563,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -26472,7 +26591,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -26496,7 +26619,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -26520,7 +26647,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "specificationList": { "description": "Specifications List", @@ -26544,7 +26675,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "database": { "description": "Database", @@ -26582,7 +26717,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -26692,7 +26834,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -26747,7 +26903,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -26822,7 +26982,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -26899,7 +27072,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -26976,7 +27162,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -27038,7 +27237,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -27106,7 +27316,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -27183,7 +27405,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -27251,7 +27486,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -27319,7 +27566,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -27387,7 +27646,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -27479,7 +27750,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -27551,7 +27838,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -27608,7 +27906,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -27742,7 +28056,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -27903,7 +28240,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -27917,7 +28280,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -27931,7 +28297,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -27945,7 +28314,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -27959,7 +28331,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -28001,7 +28376,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -28033,7 +28415,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -28068,12 +28456,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -28260,7 +28659,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -28328,7 +28760,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -28372,7 +28816,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -28386,7 +28838,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -28436,7 +28891,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -28456,7 +28920,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -28538,7 +29006,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -28630,7 +29113,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -28680,7 +29182,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -28731,7 +29242,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -28822,7 +29344,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -29008,7 +29547,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -29197,7 +29767,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "runtime": { "description": "Runtime", @@ -29256,7 +29856,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -29311,7 +29921,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -29349,7 +29977,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -29523,7 +30158,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -29654,7 +30318,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "variable": { "description": "Variable", @@ -29710,7 +30403,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -29730,7 +30433,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -29750,7 +30457,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -29776,7 +30487,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -29828,7 +30544,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -29854,7 +30579,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -29874,7 +30604,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -29889,7 +30623,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -29916,7 +30653,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -29960,7 +30702,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -29989,7 +30739,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "headers": { "description": "Headers", @@ -30009,7 +30764,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -30043,7 +30802,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -30075,7 +30840,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -30095,7 +30866,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -30115,7 +30892,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -30147,7 +30928,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -30213,7 +31000,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -30323,7 +31125,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -30385,7 +31213,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -30459,7 +31297,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -30521,7 +31379,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "securitySchemes": { diff --git a/app/config/specs/swagger2-1.7.x-client.json b/app/config/specs/swagger2-1.7.x-client.json index 95d88bb925..07a12f0dbb 100644 --- a/app/config/specs/swagger2-1.7.x-client.json +++ b/app/config/specs/swagger2-1.7.x-client.json @@ -5461,7 +5461,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -8094,7 +8094,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -8119,7 +8120,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "sessionList": { "description": "Sessions List", @@ -8144,7 +8149,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -8169,7 +8178,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -8194,7 +8207,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -8219,7 +8236,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "teamList": { "description": "Teams List", @@ -8244,7 +8265,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -8269,7 +8294,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "executionList": { "description": "Executions List", @@ -8294,7 +8323,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -8319,7 +8352,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -8344,7 +8381,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -8369,7 +8410,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -8394,7 +8439,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -8419,7 +8468,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -8444,7 +8497,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "document": { "description": "Document", @@ -8501,7 +8558,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -8635,7 +8708,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -8798,7 +8894,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -8812,7 +8934,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -8826,7 +8951,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -8840,7 +8968,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -8854,7 +8985,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -8896,7 +9030,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -8928,7 +9069,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -8963,12 +9110,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -9155,7 +9313,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -9223,7 +9414,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -9267,7 +9470,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -9281,7 +9492,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -9331,7 +9545,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -9351,7 +9574,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -9433,7 +9660,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "team": { "description": "Team", @@ -9485,7 +9727,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -9576,7 +9829,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "execution": { "description": "Execution", @@ -9709,7 +9979,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "country": { "description": "Country", @@ -9729,7 +10028,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -9749,7 +10052,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -9775,7 +10082,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -9827,7 +10139,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -9853,7 +10174,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "headers": { "description": "Headers", @@ -9873,7 +10199,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -9905,7 +10235,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -9925,7 +10261,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -9945,7 +10287,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -9977,7 +10323,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "subscriber": { "description": "Subscriber", @@ -10052,7 +10404,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -10114,7 +10486,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "externalDocs": { diff --git a/app/config/specs/swagger2-1.7.x-console.json b/app/config/specs/swagger2-1.7.x-console.json index 314564477c..32afa9e180 100644 --- a/app/config/specs/swagger2-1.7.x-console.json +++ b/app/config/specs/swagger2-1.7.x-console.json @@ -11868,7 +11868,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -35618,7 +35618,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -35643,7 +35644,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -35668,7 +35673,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -35693,7 +35702,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -35718,7 +35731,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -35743,7 +35760,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -35768,7 +35789,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -35793,7 +35818,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -35818,7 +35847,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -35843,7 +35876,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -35868,7 +35905,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -35893,7 +35934,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -35918,7 +35963,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -35943,7 +35992,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -35968,7 +36021,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "templateSiteList": { "description": "Site Templates List", @@ -35993,7 +36050,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "functionList": { "description": "Functions List", @@ -36018,7 +36079,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "templateFunctionList": { "description": "Function Templates List", @@ -36043,7 +36108,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "installationList": { "description": "Installations List", @@ -36068,7 +36137,11 @@ "required": [ "total", "installations" - ] + ], + "example": { + "total": 5, + "installations": "" + } }, "providerRepositoryFrameworkList": { "description": "Framework Provider Repositories List", @@ -36093,7 +36166,11 @@ "required": [ "total", "frameworkProviderRepositories" - ] + ], + "example": { + "total": 5, + "frameworkProviderRepositories": "" + } }, "providerRepositoryRuntimeList": { "description": "Runtime Provider Repositories List", @@ -36118,7 +36195,11 @@ "required": [ "total", "runtimeProviderRepositories" - ] + ], + "example": { + "total": 5, + "runtimeProviderRepositories": "" + } }, "branchList": { "description": "Branches List", @@ -36143,7 +36224,11 @@ "required": [ "total", "branches" - ] + ], + "example": { + "total": 5, + "branches": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -36168,7 +36253,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -36193,7 +36282,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -36218,7 +36311,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -36243,7 +36340,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "projectList": { "description": "Projects List", @@ -36268,7 +36369,11 @@ "required": [ "total", "projects" - ] + ], + "example": { + "total": 5, + "projects": "" + } }, "webhookList": { "description": "Webhooks List", @@ -36293,7 +36398,11 @@ "required": [ "total", "webhooks" - ] + ], + "example": { + "total": 5, + "webhooks": "" + } }, "keyList": { "description": "API Keys List", @@ -36318,7 +36427,11 @@ "required": [ "total", "keys" - ] + ], + "example": { + "total": 5, + "keys": "" + } }, "devKeyList": { "description": "Dev Keys List", @@ -36343,7 +36456,11 @@ "required": [ "total", "devKeys" - ] + ], + "example": { + "total": 5, + "devKeys": "" + } }, "platformList": { "description": "Platforms List", @@ -36368,7 +36485,11 @@ "required": [ "total", "platforms" - ] + ], + "example": { + "total": 5, + "platforms": "" + } }, "countryList": { "description": "Countries List", @@ -36393,7 +36514,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -36418,7 +36543,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -36443,7 +36572,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -36468,7 +36601,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -36493,7 +36630,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -36518,7 +36659,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "proxyRuleList": { "description": "Rule List", @@ -36543,7 +36688,11 @@ "required": [ "total", "rules" - ] + ], + "example": { + "total": 5, + "rules": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -36568,7 +36717,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -36593,7 +36746,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -36618,7 +36775,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -36643,7 +36804,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -36668,7 +36833,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -36693,7 +36862,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "migrationList": { "description": "Migrations List", @@ -36718,7 +36891,11 @@ "required": [ "total", "migrations" - ] + ], + "example": { + "total": 5, + "migrations": "" + } }, "specificationList": { "description": "Specifications List", @@ -36743,7 +36920,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "vcsContentList": { "description": "VCS Content List", @@ -36768,7 +36949,11 @@ "required": [ "total", "contents" - ] + ], + "example": { + "total": 5, + "contents": "" + } }, "database": { "description": "Database", @@ -36806,7 +36991,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -36917,7 +37109,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -36972,7 +37178,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -37047,7 +37257,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -37124,7 +37347,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -37201,7 +37437,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -37263,7 +37512,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -37331,7 +37591,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -37408,7 +37680,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -37476,7 +37761,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -37544,7 +37841,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -37612,7 +37921,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -37704,7 +38025,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -37776,7 +38113,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -37833,7 +38181,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -37967,7 +38331,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -38130,7 +38517,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -38144,7 +38557,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -38158,7 +38574,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -38172,7 +38591,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -38186,7 +38608,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -38228,7 +38653,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -38260,7 +38692,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -38295,12 +38733,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -38487,7 +38936,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -38555,7 +39037,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -38599,7 +39093,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -38613,7 +39115,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -38663,7 +39168,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -38683,7 +39197,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -38765,7 +39283,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -38857,7 +39390,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -38907,7 +39459,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -38959,7 +39520,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -39050,7 +39622,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -39237,7 +39826,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "templateSite": { "description": "Template Site", @@ -39334,7 +39954,22 @@ "providerOwner", "providerVersion", "variables" - ] + ], + "example": { + "key": "starter", + "name": "Starter site", + "tagline": "Minimal web app integrating with Appwrite.", + "demoUrl": "https:\/\/nextjs-starter.appwrite.network\/", + "screenshotDark": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-dark.png", + "screenshotLight": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-light.png", + "useCases": "Starter", + "frameworks": [], + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [] + } }, "templateFramework": { "description": "Template Framework", @@ -39396,7 +40031,18 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/build", + "providerRootDirectory": ".\/svelte-kit\/starter", + "buildRuntime": "node-22", + "adapter": "ssr", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -39586,7 +40232,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "templateFunction": { "description": "Template Function", @@ -39717,7 +40393,26 @@ "providerVersion", "variables", "scopes" - ] + ], + "example": { + "icon": "icon-lightning-bolt", + "id": "starter", + "name": "Starter function", + "tagline": "A simple function to get started.", + "permissions": "any", + "events": "account.create", + "cron": "0 0 * * *", + "timeout": 300, + "useCases": "Starter", + "runtimes": [], + "instructions": "For documentation and instructions check out .", + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [], + "scopes": "users.read" + } }, "templateRuntime": { "description": "Template Runtime", @@ -39749,7 +40444,13 @@ "commands", "entrypoint", "providerRootDirectory" - ] + ], + "example": { + "name": "node-19.0", + "commands": "npm install", + "entrypoint": "index.js", + "providerRootDirectory": "node\/starter" + } }, "templateVariable": { "description": "Template Variable", @@ -39799,7 +40500,16 @@ "placeholder", "required", "type" - ] + ], + "example": { + "name": "APPWRITE_DATABASE_ID", + "description": "The ID of the Appwrite database that contains the collection to sync.", + "value": "512", + "secret": false, + "placeholder": "64a55...7b912", + "required": false, + "type": "password" + } }, "installation": { "description": "Installation", @@ -39843,7 +40553,15 @@ "provider", "organization", "providerInstallationId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "provider": "github", + "organization": "appwrite", + "providerInstallationId": "5322" + } }, "providerRepository": { "description": "ProviderRepository", @@ -39874,6 +40592,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39886,8 +40609,18 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime" + } }, "providerRepositoryFramework": { "description": "ProviderRepositoryFramework", @@ -39918,6 +40651,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39935,9 +40673,20 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt", "framework" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "framework": "nextjs" + } }, "providerRepositoryRuntime": { "description": "ProviderRepositoryRuntime", @@ -39968,6 +40717,11 @@ "description": "Is VCS (Version Control System) repository private?", "x-example": true }, + "defaultBranch": { + "type": "string", + "description": "VCS (Version Control System) repository's default branch name.", + "x-example": "main" + }, "pushedAt": { "type": "string", "description": "Last commit date in ISO 8601 format.", @@ -39985,9 +40739,20 @@ "organization", "provider", "private", + "defaultBranch", "pushedAt", "runtime" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "runtime": "node-22" + } }, "detectionFramework": { "description": "DetectionFramework", @@ -40019,7 +40784,13 @@ "installCommand", "buildCommand", "outputDirectory" - ] + ], + "example": { + "framework": "nuxt", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "dist" + } }, "detectionRuntime": { "description": "DetectionRuntime", @@ -40045,7 +40816,12 @@ "runtime", "entrypoint", "commands" - ] + ], + "example": { + "runtime": "node", + "entrypoint": "index.js", + "commands": "npm install && npm run build" + } }, "vcsContent": { "description": "VcsContents", @@ -40072,7 +40848,12 @@ }, "required": [ "name" - ] + ], + "example": { + "size": 1523, + "isDirectory": true, + "name": "Main.java" + } }, "branch": { "description": "Branch", @@ -40086,7 +40867,10 @@ }, "required": [ "name" - ] + ], + "example": { + "name": "main" + } }, "runtime": { "description": "Runtime", @@ -40145,7 +40929,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -40201,7 +40995,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -40239,7 +41051,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -40413,7 +41232,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -40546,7 +41394,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "project": { "description": "Project", @@ -40948,7 +41825,73 @@ "serviceStatusForFunctions", "serviceStatusForGraphql", "serviceStatusForMessaging" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "New Project", + "description": "This is a new project.", + "teamId": "1592981250", + "logo": "5f5c451b403cb", + "url": "5f5c451b403cb", + "legalName": "Company LTD.", + "legalCountry": "US", + "legalState": "New York", + "legalCity": "New York City.", + "legalAddress": "620 Eighth Avenue, New York, NY 10018", + "legalTaxId": "131102020", + "authDuration": 60, + "authLimit": 100, + "authSessionsLimit": 10, + "authPasswordHistory": 5, + "authPasswordDictionary": true, + "authPersonalDataCheck": true, + "authMockNumbers": [ + {} + ], + "authSessionAlerts": true, + "authMembershipsUserName": true, + "authMembershipsUserEmail": true, + "authMembershipsMfa": true, + "oAuthProviders": [ + {} + ], + "platforms": {}, + "webhooks": {}, + "keys": {}, + "devKeys": {}, + "smtpEnabled": false, + "smtpSenderName": "John Appwrite", + "smtpSenderEmail": "john@appwrite.io", + "smtpReplyTo": "support@appwrite.io", + "smtpHost": "mail.appwrite.io", + "smtpPort": 25, + "smtpUsername": "emailuser", + "smtpPassword": "securepassword", + "smtpSecure": "tls", + "pingCount": 1, + "pingedAt": "2020-10-15T06:38:00.000+00:00", + "authEmailPassword": true, + "authUsersAuthMagicURL": true, + "authEmailOtp": true, + "authAnonymous": true, + "authInvites": true, + "authJWT": true, + "authPhone": true, + "serviceStatusForAccount": true, + "serviceStatusForAvatars": true, + "serviceStatusForDatabases": true, + "serviceStatusForLocale": true, + "serviceStatusForHealth": true, + "serviceStatusForStorage": true, + "serviceStatusForTeams": true, + "serviceStatusForUsers": true, + "serviceStatusForSites": true, + "serviceStatusForFunctions": true, + "serviceStatusForGraphql": true, + "serviceStatusForMessaging": true + } }, "webhook": { "description": "Webhook", @@ -41038,7 +41981,22 @@ "enabled", "logs", "attempts" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Webhook", + "url": "https:\/\/example.com\/webhook", + "events": "database.collections.update", + "security": true, + "httpUser": "username", + "httpPass": "password", + "signatureKey": "ad3d581ca230e2b7059c545e5a", + "enabled": true, + "logs": "Failed to connect to remote server.", + "attempts": 10 + } }, "key": { "description": "Key", @@ -41106,7 +42064,18 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "scopes": "users.read", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "devKey": { "description": "DevKey", @@ -41165,7 +42134,17 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Dev API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "mockNumber": { "description": "Mock Number", @@ -41185,7 +42164,11 @@ "required": [ "phone", "otp" - ] + ], + "example": { + "phone": "+1612842323", + "otp": "123456" + } }, "authProvider": { "description": "AuthProvider", @@ -41223,7 +42206,14 @@ "appId", "secret", "enabled" - ] + ], + "example": { + "key": "github", + "name": "GitHub", + "appId": "259125845563242502", + "secret": "Bpw_g9c2TGXxfgLshDbSaL8tsCcqgczQ", + "enabled": "" + } }, "platform": { "description": "Platform", @@ -41291,7 +42281,19 @@ "hostname", "httpUser", "httpPass" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Web App", + "type": "web", + "key": "com.company.appname", + "store": "", + "hostname": true, + "httpUser": "username", + "httpPass": "password" + } }, "variable": { "description": "Variable", @@ -41347,7 +42349,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -41367,7 +42379,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -41387,7 +42403,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -41413,7 +42433,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -41465,7 +42490,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -41491,7 +42525,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -41511,7 +42550,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -41526,7 +42569,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -41553,7 +42599,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -41597,7 +42648,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -41626,7 +42685,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "metric": { "description": "Metric", @@ -41647,7 +42711,11 @@ "required": [ "value", "date" - ] + ], + "example": { + "value": 1, + "date": "2020-10-15T06:38:00.000+00:00" + } }, "metricBreakdown": { "description": "Metric Breakdown", @@ -41681,7 +42749,13 @@ "required": [ "name", "value" - ] + ], + "example": { + "resourceId": "5e5ea5c16897e", + "name": "Documents", + "value": 1, + "estimate": 1 + } }, "usageDatabases": { "description": "UsageDatabases", @@ -41797,7 +42871,22 @@ "storage", "databasesReads", "databasesWrites" - ] + ], + "example": { + "range": "30d", + "databasesTotal": 0, + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "databases": [], + "collections": [], + "documents": [], + "storage": [], + "databasesReads": [], + "databasesWrites": [] + } }, "usageDatabase": { "description": "UsageDatabase", @@ -41896,7 +42985,20 @@ "storage", "databaseReads", "databaseWrites" - ] + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } }, "usageCollection": { "description": "UsageCollection", @@ -41927,7 +43029,12 @@ "range", "documentsTotal", "documents" - ] + ], + "example": { + "range": "30d", + "documentsTotal": 0, + "documents": [] + } }, "usageUsers": { "description": "UsageUsers", @@ -41975,7 +43082,14 @@ "sessionsTotal", "users", "sessions" - ] + ], + "example": { + "range": "30d", + "usersTotal": 0, + "sessionsTotal": 0, + "users": [], + "sessions": [] + } }, "usageStorage": { "description": "StorageUsage", @@ -42040,7 +43154,16 @@ "buckets", "files", "storage" - ] + ], + "example": { + "range": "30d", + "bucketsTotal": 0, + "filesTotal": 0, + "filesStorageTotal": 0, + "buckets": [], + "files": [], + "storage": [] + } }, "usageBuckets": { "description": "UsageBuckets", @@ -42105,7 +43228,16 @@ "storage", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "range": "30d", + "filesTotal": 0, + "filesStorageTotal": 0, + "files": [], + "storage": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "usageFunctions": { "description": "UsageFunctions", @@ -42323,7 +43455,34 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "functionsTotal": 0, + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "functions": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageFunction": { "description": "UsageFunction", @@ -42531,7 +43690,33 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageSites": { "description": "UsageSites", @@ -42800,7 +43985,40 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "sitesTotal": 0, + "sites": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageSite": { "description": "UsageSite", @@ -43059,7 +44277,39 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageProject": { "description": "UsageProject", @@ -43326,7 +44576,40 @@ "databasesWrites", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "executionsTotal": 0, + "documentsTotal": 0, + "databasesTotal": 0, + "databasesStorageTotal": 0, + "usersTotal": 0, + "filesStorageTotal": 0, + "functionsStorageTotal": 0, + "buildsStorageTotal": 0, + "deploymentsStorageTotal": 0, + "bucketsTotal": 0, + "executionsMbSecondsTotal": 0, + "buildsMbSecondsTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "requests": [], + "network": [], + "users": [], + "executions": [], + "executionsBreakdown": [], + "bucketsBreakdown": [], + "databasesStorageBreakdown": [], + "executionsMbSecondsBreakdown": [], + "buildsMbSecondsBreakdown": [], + "functionsStorageBreakdown": [], + "authPhoneTotal": 0, + "authPhoneEstimate": 0, + "authPhoneCountryBreakdown": [], + "databasesReads": [], + "databasesWrites": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "headers": { "description": "Headers", @@ -43346,7 +44629,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -43380,7 +44667,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "proxyRule": { "description": "Rule", @@ -43479,7 +44772,24 @@ "status", "logs", "renewAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "domain": "appwrite.company.com", + "type": "deployment", + "trigger": "manual", + "redirectUrl": "https:\/\/appwrite.io\/docs", + "redirectStatusCode": 301, + "deploymentId": "n3u9feiwmf", + "deploymentResourceType": "function", + "deploymentResourceId": "n3u9feiwmf", + "deploymentVcsProviderBranch": "function", + "status": "verified", + "logs": "HTTP challegne failed.", + "renewAt": "datetime" + } }, "smsTemplate": { "description": "SmsTemplate", @@ -43505,7 +44815,12 @@ "type", "locale", "message" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account." + } }, "emailTemplate": { "description": "EmailTemplate", @@ -43555,7 +44870,16 @@ "senderEmail", "replyTo", "subject" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account.", + "senderName": "My User", + "senderEmail": "mail@appwrite.io", + "replyTo": "emails@appwrite.io", + "subject": "Please verify your email address" + } }, "consoleVariables": { "description": "Console Variables", @@ -43643,7 +44967,22 @@ "_APP_DOMAIN_FUNCTIONS", "_APP_OPTIONS_FORCE_HTTPS", "_APP_DOMAINS_NAMESERVERS" - ] + ], + "example": { + "_APP_DOMAIN_TARGET_CNAME": "appwrite.io", + "_APP_DOMAIN_TARGET_A": "127.0.0.1", + "_APP_DOMAIN_TARGET_AAAA": "::1", + "_APP_STORAGE_LIMIT": "30000000", + "_APP_COMPUTE_SIZE_LIMIT": "30000000", + "_APP_USAGE_STATS": "enabled", + "_APP_VCS_ENABLED": true, + "_APP_DOMAIN_ENABLED": true, + "_APP_ASSISTANT_ENABLED": true, + "_APP_DOMAIN_SITES": "sites.localhost", + "_APP_DOMAIN_FUNCTIONS": "functions.localhost", + "_APP_OPTIONS_FORCE_HTTPS": "enabled", + "_APP_DOMAINS_NAMESERVERS": "ns1.example.com,ns2.example.com" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -43675,7 +45014,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -43695,7 +45040,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -43715,7 +45066,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -43747,7 +45102,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -43814,7 +45175,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -43925,7 +45301,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -43987,7 +45389,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -44062,7 +45474,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -44124,7 +45556,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } }, "migration": { "description": "Migration", @@ -44214,7 +45657,23 @@ "statusCounters", "resourceData", "errors" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "status": "pending", + "stage": "init", + "source": "Appwrite", + "destination": "Appwrite", + "resources": [ + "user" + ], + "resourceId": "databaseId:collectionId", + "statusCounters": "{\"Database\": {\"PENDING\": 0, \"SUCCESS\": 1, \"ERROR\": 0, \"SKIP\": 0, \"PROCESSING\": 0, \"WARNING\": 0}}", + "resourceData": "[{\"resource\":\"Database\",\"id\":\"public\",\"status\":\"SUCCESS\",\"message\":\"\"}]", + "errors": [] + } }, "migrationReport": { "description": "Migration Report", @@ -44284,7 +45743,18 @@ "function", "size", "version" - ] + ], + "example": { + "user": 20, + "team": 20, + "database": 20, + "document": 20, + "file": 20, + "bucket": 20, + "function": 20, + "size": 30000, + "version": "1.4.0" + } } }, "externalDocs": { diff --git a/app/config/specs/swagger2-1.7.x-server.json b/app/config/specs/swagger2-1.7.x-server.json index c67d26dd54..391adc2dfc 100644 --- a/app/config/specs/swagger2-1.7.x-server.json +++ b/app/config/specs/swagger2-1.7.x-server.json @@ -10763,7 +10763,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -25977,7 +25977,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -26002,7 +26003,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -26027,7 +26032,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -26052,7 +26061,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -26077,7 +26090,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -26102,7 +26119,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -26127,7 +26148,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -26152,7 +26177,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -26177,7 +26206,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -26202,7 +26235,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -26227,7 +26264,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -26252,7 +26293,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -26277,7 +26322,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -26302,7 +26351,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -26327,7 +26380,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "functionList": { "description": "Functions List", @@ -26352,7 +26409,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -26377,7 +26438,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -26402,7 +26467,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -26427,7 +26496,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -26452,7 +26525,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -26477,7 +26554,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -26502,7 +26583,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -26527,7 +26612,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -26552,7 +26641,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -26577,7 +26670,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -26602,7 +26699,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -26627,7 +26728,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -26652,7 +26757,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -26677,7 +26786,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -26702,7 +26815,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -26727,7 +26844,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -26752,7 +26873,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "specificationList": { "description": "Specifications List", @@ -26777,7 +26902,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "database": { "description": "Database", @@ -26815,7 +26944,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -26926,7 +27062,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -26981,7 +27131,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -27056,7 +27210,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -27133,7 +27300,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -27210,7 +27390,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -27272,7 +27465,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -27340,7 +27544,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -27417,7 +27633,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -27485,7 +27714,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -27553,7 +27794,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -27621,7 +27874,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -27713,7 +27978,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -27785,7 +28066,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -27842,7 +28134,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -27976,7 +28284,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -28139,7 +28470,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -28153,7 +28510,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -28167,7 +28527,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -28181,7 +28544,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -28195,7 +28561,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -28237,7 +28606,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -28269,7 +28645,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -28304,12 +28686,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -28496,7 +28889,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -28564,7 +28990,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -28608,7 +29046,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -28622,7 +29068,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -28672,7 +29121,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -28692,7 +29150,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -28774,7 +29236,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -28866,7 +29343,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -28916,7 +29412,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -28968,7 +29473,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -29059,7 +29575,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -29246,7 +29779,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -29436,7 +30000,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "runtime": { "description": "Runtime", @@ -29495,7 +30089,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -29551,7 +30155,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -29589,7 +30211,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -29763,7 +30392,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -29896,7 +30554,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "variable": { "description": "Variable", @@ -29952,7 +30639,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -29972,7 +30669,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -29992,7 +30693,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -30018,7 +30723,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -30070,7 +30780,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -30096,7 +30815,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -30116,7 +30840,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -30131,7 +30859,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -30158,7 +30889,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -30202,7 +30938,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -30231,7 +30975,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "headers": { "description": "Headers", @@ -30251,7 +31000,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -30285,7 +31038,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -30317,7 +31076,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -30337,7 +31102,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -30357,7 +31128,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -30389,7 +31164,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -30456,7 +31237,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -30567,7 +31363,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -30629,7 +31451,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -30704,7 +31536,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -30766,7 +31618,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "externalDocs": { diff --git a/app/config/specs/swagger2-latest-client.json b/app/config/specs/swagger2-latest-client.json index 23f1e122b8..07a12f0dbb 100644 --- a/app/config/specs/swagger2-latest-client.json +++ b/app/config/specs/swagger2-latest-client.json @@ -4626,30 +4626,6 @@ } ], "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection) API or directly from your database console." - }, - { - "name": "createDocuments", - "auth": { - "Admin": [], - "Key": [] - }, - "parameters": [ - "databaseId", - "collectionId", - "documents" - ], - "required": [ - "databaseId", - "collectionId", - "documents" - ], - "responses": [ - { - "code": 201, - "model": "#\/definitions\/documentList" - } - ], - "description": "**WARNING: Experimental Feature** - This endpoint is experimental and not yet officially supported. It may be subject to breaking changes or removal in future versions.\n\nCreate new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection) API or directly from your database console." } ], "auth": { @@ -5485,7 +5461,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -8118,7 +8094,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -8143,7 +8120,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "sessionList": { "description": "Sessions List", @@ -8168,7 +8149,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -8193,7 +8178,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -8218,7 +8207,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -8243,7 +8236,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "teamList": { "description": "Teams List", @@ -8268,7 +8265,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -8293,7 +8294,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "executionList": { "description": "Executions List", @@ -8318,7 +8323,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -8343,7 +8352,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -8368,7 +8381,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -8393,7 +8410,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -8418,7 +8439,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -8443,7 +8468,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -8468,7 +8497,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "document": { "description": "Document", @@ -8525,7 +8558,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -8659,7 +8708,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -8822,7 +8894,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -8836,7 +8934,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -8850,7 +8951,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -8864,7 +8968,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -8878,7 +8985,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -8920,7 +9030,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -8952,7 +9069,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -8987,12 +9110,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -9179,7 +9313,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -9247,7 +9414,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -9291,7 +9470,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -9305,7 +9492,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -9355,7 +9545,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -9375,7 +9574,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -9457,7 +9660,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "team": { "description": "Team", @@ -9509,7 +9727,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -9600,7 +9829,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "execution": { "description": "Execution", @@ -9733,7 +9979,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "country": { "description": "Country", @@ -9753,7 +10028,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -9773,7 +10052,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -9799,7 +10082,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -9851,7 +10139,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -9877,7 +10174,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "headers": { "description": "Headers", @@ -9897,7 +10199,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -9929,7 +10235,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -9949,7 +10261,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -9969,7 +10287,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -10001,7 +10323,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "subscriber": { "description": "Subscriber", @@ -10076,7 +10404,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -10138,7 +10486,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "externalDocs": { diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 92317a7532..32afa9e180 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -11868,7 +11868,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -35618,7 +35618,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -35643,7 +35644,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -35668,7 +35673,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -35693,7 +35702,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -35718,7 +35731,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -35743,7 +35760,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -35768,7 +35789,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -35793,7 +35818,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -35818,7 +35847,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -35843,7 +35876,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -35868,7 +35905,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -35893,7 +35934,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -35918,7 +35963,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -35943,7 +35992,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -35968,7 +36021,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "templateSiteList": { "description": "Site Templates List", @@ -35993,7 +36050,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "functionList": { "description": "Functions List", @@ -36018,7 +36079,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "templateFunctionList": { "description": "Function Templates List", @@ -36043,7 +36108,11 @@ "required": [ "total", "templates" - ] + ], + "example": { + "total": 5, + "templates": "" + } }, "installationList": { "description": "Installations List", @@ -36068,7 +36137,11 @@ "required": [ "total", "installations" - ] + ], + "example": { + "total": 5, + "installations": "" + } }, "providerRepositoryFrameworkList": { "description": "Framework Provider Repositories List", @@ -36093,7 +36166,11 @@ "required": [ "total", "frameworkProviderRepositories" - ] + ], + "example": { + "total": 5, + "frameworkProviderRepositories": "" + } }, "providerRepositoryRuntimeList": { "description": "Runtime Provider Repositories List", @@ -36118,7 +36195,11 @@ "required": [ "total", "runtimeProviderRepositories" - ] + ], + "example": { + "total": 5, + "runtimeProviderRepositories": "" + } }, "branchList": { "description": "Branches List", @@ -36143,7 +36224,11 @@ "required": [ "total", "branches" - ] + ], + "example": { + "total": 5, + "branches": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -36168,7 +36253,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -36193,7 +36282,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -36218,7 +36311,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -36243,7 +36340,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "projectList": { "description": "Projects List", @@ -36268,7 +36369,11 @@ "required": [ "total", "projects" - ] + ], + "example": { + "total": 5, + "projects": "" + } }, "webhookList": { "description": "Webhooks List", @@ -36293,7 +36398,11 @@ "required": [ "total", "webhooks" - ] + ], + "example": { + "total": 5, + "webhooks": "" + } }, "keyList": { "description": "API Keys List", @@ -36318,7 +36427,11 @@ "required": [ "total", "keys" - ] + ], + "example": { + "total": 5, + "keys": "" + } }, "devKeyList": { "description": "Dev Keys List", @@ -36343,7 +36456,11 @@ "required": [ "total", "devKeys" - ] + ], + "example": { + "total": 5, + "devKeys": "" + } }, "platformList": { "description": "Platforms List", @@ -36368,7 +36485,11 @@ "required": [ "total", "platforms" - ] + ], + "example": { + "total": 5, + "platforms": "" + } }, "countryList": { "description": "Countries List", @@ -36393,7 +36514,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -36418,7 +36543,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -36443,7 +36572,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -36468,7 +36601,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -36493,7 +36630,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -36518,7 +36659,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "proxyRuleList": { "description": "Rule List", @@ -36543,7 +36688,11 @@ "required": [ "total", "rules" - ] + ], + "example": { + "total": 5, + "rules": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -36568,7 +36717,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -36593,7 +36746,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -36618,7 +36775,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -36643,7 +36804,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -36668,7 +36833,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -36693,7 +36862,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "migrationList": { "description": "Migrations List", @@ -36718,7 +36891,11 @@ "required": [ "total", "migrations" - ] + ], + "example": { + "total": 5, + "migrations": "" + } }, "specificationList": { "description": "Specifications List", @@ -36743,7 +36920,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "vcsContentList": { "description": "VCS Content List", @@ -36768,7 +36949,11 @@ "required": [ "total", "contents" - ] + ], + "example": { + "total": 5, + "contents": "" + } }, "database": { "description": "Database", @@ -36806,7 +36991,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -36917,7 +37109,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -36972,7 +37178,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -37047,7 +37257,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -37124,7 +37347,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -37201,7 +37437,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -37263,7 +37512,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -37331,7 +37591,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -37408,7 +37680,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -37476,7 +37761,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -37544,7 +37841,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -37612,7 +37921,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -37704,7 +38025,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -37776,7 +38113,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -37833,7 +38181,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -37967,7 +38331,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -38130,7 +38517,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -38144,7 +38557,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -38158,7 +38574,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -38172,7 +38591,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -38186,7 +38608,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -38228,7 +38653,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -38260,7 +38692,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -38295,12 +38733,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -38487,7 +38936,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -38555,7 +39037,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -38599,7 +39093,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -38613,7 +39115,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -38663,7 +39168,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -38683,7 +39197,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -38765,7 +39283,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -38857,7 +39390,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -38907,7 +39459,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -38959,7 +39520,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -39050,7 +39622,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -39237,7 +39826,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "templateSite": { "description": "Template Site", @@ -39334,7 +39954,22 @@ "providerOwner", "providerVersion", "variables" - ] + ], + "example": { + "key": "starter", + "name": "Starter site", + "tagline": "Minimal web app integrating with Appwrite.", + "demoUrl": "https:\/\/nextjs-starter.appwrite.network\/", + "screenshotDark": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-dark.png", + "screenshotLight": "https:\/\/cloud.appwrite.io\/images\/sites\/templates\/template-for-blog-light.png", + "useCases": "Starter", + "frameworks": [], + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [] + } }, "templateFramework": { "description": "Template Framework", @@ -39396,7 +40031,18 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/build", + "providerRootDirectory": ".\/svelte-kit\/starter", + "buildRuntime": "node-22", + "adapter": "ssr", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -39586,7 +40232,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "templateFunction": { "description": "Template Function", @@ -39717,7 +40393,26 @@ "providerVersion", "variables", "scopes" - ] + ], + "example": { + "icon": "icon-lightning-bolt", + "id": "starter", + "name": "Starter function", + "tagline": "A simple function to get started.", + "permissions": "any", + "events": "account.create", + "cron": "0 0 * * *", + "timeout": 300, + "useCases": "Starter", + "runtimes": [], + "instructions": "For documentation and instructions check out .", + "vcsProvider": "github", + "providerRepositoryId": "templates", + "providerOwner": "appwrite", + "providerVersion": "main", + "variables": [], + "scopes": "users.read" + } }, "templateRuntime": { "description": "Template Runtime", @@ -39749,7 +40444,13 @@ "commands", "entrypoint", "providerRootDirectory" - ] + ], + "example": { + "name": "node-19.0", + "commands": "npm install", + "entrypoint": "index.js", + "providerRootDirectory": "node\/starter" + } }, "templateVariable": { "description": "Template Variable", @@ -39799,7 +40500,16 @@ "placeholder", "required", "type" - ] + ], + "example": { + "name": "APPWRITE_DATABASE_ID", + "description": "The ID of the Appwrite database that contains the collection to sync.", + "value": "512", + "secret": false, + "placeholder": "64a55...7b912", + "required": false, + "type": "password" + } }, "installation": { "description": "Installation", @@ -39843,7 +40553,15 @@ "provider", "organization", "providerInstallationId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "provider": "github", + "organization": "appwrite", + "providerInstallationId": "5322" + } }, "providerRepository": { "description": "ProviderRepository", @@ -39893,7 +40611,16 @@ "private", "defaultBranch", "pushedAt" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime" + } }, "providerRepositoryFramework": { "description": "ProviderRepositoryFramework", @@ -39949,7 +40676,17 @@ "defaultBranch", "pushedAt", "framework" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "framework": "nextjs" + } }, "providerRepositoryRuntime": { "description": "ProviderRepositoryRuntime", @@ -40005,7 +40742,17 @@ "defaultBranch", "pushedAt", "runtime" - ] + ], + "example": { + "id": "5e5ea5c16897e", + "name": "appwrite", + "organization": "appwrite", + "provider": "github", + "private": true, + "defaultBranch": "main", + "pushedAt": "datetime", + "runtime": "node-22" + } }, "detectionFramework": { "description": "DetectionFramework", @@ -40037,7 +40784,13 @@ "installCommand", "buildCommand", "outputDirectory" - ] + ], + "example": { + "framework": "nuxt", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "dist" + } }, "detectionRuntime": { "description": "DetectionRuntime", @@ -40063,7 +40816,12 @@ "runtime", "entrypoint", "commands" - ] + ], + "example": { + "runtime": "node", + "entrypoint": "index.js", + "commands": "npm install && npm run build" + } }, "vcsContent": { "description": "VcsContents", @@ -40090,7 +40848,12 @@ }, "required": [ "name" - ] + ], + "example": { + "size": 1523, + "isDirectory": true, + "name": "Main.java" + } }, "branch": { "description": "Branch", @@ -40104,7 +40867,10 @@ }, "required": [ "name" - ] + ], + "example": { + "name": "main" + } }, "runtime": { "description": "Runtime", @@ -40163,7 +40929,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -40219,7 +40995,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -40257,7 +41051,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -40431,7 +41232,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -40564,7 +41394,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "project": { "description": "Project", @@ -40966,7 +41825,73 @@ "serviceStatusForFunctions", "serviceStatusForGraphql", "serviceStatusForMessaging" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "New Project", + "description": "This is a new project.", + "teamId": "1592981250", + "logo": "5f5c451b403cb", + "url": "5f5c451b403cb", + "legalName": "Company LTD.", + "legalCountry": "US", + "legalState": "New York", + "legalCity": "New York City.", + "legalAddress": "620 Eighth Avenue, New York, NY 10018", + "legalTaxId": "131102020", + "authDuration": 60, + "authLimit": 100, + "authSessionsLimit": 10, + "authPasswordHistory": 5, + "authPasswordDictionary": true, + "authPersonalDataCheck": true, + "authMockNumbers": [ + {} + ], + "authSessionAlerts": true, + "authMembershipsUserName": true, + "authMembershipsUserEmail": true, + "authMembershipsMfa": true, + "oAuthProviders": [ + {} + ], + "platforms": {}, + "webhooks": {}, + "keys": {}, + "devKeys": {}, + "smtpEnabled": false, + "smtpSenderName": "John Appwrite", + "smtpSenderEmail": "john@appwrite.io", + "smtpReplyTo": "support@appwrite.io", + "smtpHost": "mail.appwrite.io", + "smtpPort": 25, + "smtpUsername": "emailuser", + "smtpPassword": "securepassword", + "smtpSecure": "tls", + "pingCount": 1, + "pingedAt": "2020-10-15T06:38:00.000+00:00", + "authEmailPassword": true, + "authUsersAuthMagicURL": true, + "authEmailOtp": true, + "authAnonymous": true, + "authInvites": true, + "authJWT": true, + "authPhone": true, + "serviceStatusForAccount": true, + "serviceStatusForAvatars": true, + "serviceStatusForDatabases": true, + "serviceStatusForLocale": true, + "serviceStatusForHealth": true, + "serviceStatusForStorage": true, + "serviceStatusForTeams": true, + "serviceStatusForUsers": true, + "serviceStatusForSites": true, + "serviceStatusForFunctions": true, + "serviceStatusForGraphql": true, + "serviceStatusForMessaging": true + } }, "webhook": { "description": "Webhook", @@ -41056,7 +41981,22 @@ "enabled", "logs", "attempts" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Webhook", + "url": "https:\/\/example.com\/webhook", + "events": "database.collections.update", + "security": true, + "httpUser": "username", + "httpPass": "password", + "signatureKey": "ad3d581ca230e2b7059c545e5a", + "enabled": true, + "logs": "Failed to connect to remote server.", + "attempts": 10 + } }, "key": { "description": "Key", @@ -41124,7 +42064,18 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "scopes": "users.read", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "devKey": { "description": "DevKey", @@ -41183,7 +42134,17 @@ "secret", "accessedAt", "sdks" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Dev API Key", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "919c2d18fb5d4...a2ae413da83346ad2", + "accessedAt": "2020-10-15T06:38:00.000+00:00", + "sdks": "appwrite:flutter" + } }, "mockNumber": { "description": "Mock Number", @@ -41203,7 +42164,11 @@ "required": [ "phone", "otp" - ] + ], + "example": { + "phone": "+1612842323", + "otp": "123456" + } }, "authProvider": { "description": "AuthProvider", @@ -41241,7 +42206,14 @@ "appId", "secret", "enabled" - ] + ], + "example": { + "key": "github", + "name": "GitHub", + "appId": "259125845563242502", + "secret": "Bpw_g9c2TGXxfgLshDbSaL8tsCcqgczQ", + "enabled": "" + } }, "platform": { "description": "Platform", @@ -41309,7 +42281,19 @@ "hostname", "httpUser", "httpPass" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Web App", + "type": "web", + "key": "com.company.appname", + "store": "", + "hostname": true, + "httpUser": "username", + "httpPass": "password" + } }, "variable": { "description": "Variable", @@ -41365,7 +42349,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -41385,7 +42379,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -41405,7 +42403,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -41431,7 +42433,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -41483,7 +42490,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -41509,7 +42525,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -41529,7 +42550,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -41544,7 +42569,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -41571,7 +42599,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -41615,7 +42648,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -41644,7 +42685,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "metric": { "description": "Metric", @@ -41665,7 +42711,11 @@ "required": [ "value", "date" - ] + ], + "example": { + "value": 1, + "date": "2020-10-15T06:38:00.000+00:00" + } }, "metricBreakdown": { "description": "Metric Breakdown", @@ -41699,7 +42749,13 @@ "required": [ "name", "value" - ] + ], + "example": { + "resourceId": "5e5ea5c16897e", + "name": "Documents", + "value": 1, + "estimate": 1 + } }, "usageDatabases": { "description": "UsageDatabases", @@ -41815,7 +42871,22 @@ "storage", "databasesReads", "databasesWrites" - ] + ], + "example": { + "range": "30d", + "databasesTotal": 0, + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "databases": [], + "collections": [], + "documents": [], + "storage": [], + "databasesReads": [], + "databasesWrites": [] + } }, "usageDatabase": { "description": "UsageDatabase", @@ -41914,7 +42985,20 @@ "storage", "databaseReads", "databaseWrites" - ] + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } }, "usageCollection": { "description": "UsageCollection", @@ -41945,7 +43029,12 @@ "range", "documentsTotal", "documents" - ] + ], + "example": { + "range": "30d", + "documentsTotal": 0, + "documents": [] + } }, "usageUsers": { "description": "UsageUsers", @@ -41993,7 +43082,14 @@ "sessionsTotal", "users", "sessions" - ] + ], + "example": { + "range": "30d", + "usersTotal": 0, + "sessionsTotal": 0, + "users": [], + "sessions": [] + } }, "usageStorage": { "description": "StorageUsage", @@ -42058,7 +43154,16 @@ "buckets", "files", "storage" - ] + ], + "example": { + "range": "30d", + "bucketsTotal": 0, + "filesTotal": 0, + "filesStorageTotal": 0, + "buckets": [], + "files": [], + "storage": [] + } }, "usageBuckets": { "description": "UsageBuckets", @@ -42123,7 +43228,16 @@ "storage", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "range": "30d", + "filesTotal": 0, + "filesStorageTotal": 0, + "files": [], + "storage": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "usageFunctions": { "description": "UsageFunctions", @@ -42341,7 +43455,34 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "functionsTotal": 0, + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "functions": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageFunction": { "description": "UsageFunction", @@ -42549,7 +43690,33 @@ "executionsMbSeconds", "buildsSuccess", "buildsFailed" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [] + } }, "usageSites": { "description": "UsageSites", @@ -42818,7 +43985,40 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "sitesTotal": 0, + "sites": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageSite": { "description": "UsageSite", @@ -43077,7 +44277,39 @@ "inbound", "outboundTotal", "outbound" - ] + ], + "example": { + "range": "30d", + "deploymentsTotal": 0, + "deploymentsStorageTotal": 0, + "buildsTotal": 0, + "buildsSuccessTotal": 0, + "buildsFailedTotal": 0, + "buildsStorageTotal": 0, + "buildsTimeTotal": 0, + "buildsTimeAverage": 0, + "buildsMbSecondsTotal": 0, + "executionsTotal": 0, + "executionsTimeTotal": 0, + "executionsMbSecondsTotal": 0, + "deployments": [], + "deploymentsStorage": [], + "builds": [], + "buildsStorage": [], + "buildsTime": [], + "buildsMbSeconds": [], + "executions": [], + "executionsTime": [], + "executionsMbSeconds": [], + "buildsSuccess": [], + "buildsFailed": [], + "requestsTotal": 0, + "requests": [], + "inboundTotal": 0, + "inbound": [], + "outboundTotal": 0, + "outbound": [] + } }, "usageProject": { "description": "UsageProject", @@ -43344,7 +44576,40 @@ "databasesWrites", "imageTransformations", "imageTransformationsTotal" - ] + ], + "example": { + "executionsTotal": 0, + "documentsTotal": 0, + "databasesTotal": 0, + "databasesStorageTotal": 0, + "usersTotal": 0, + "filesStorageTotal": 0, + "functionsStorageTotal": 0, + "buildsStorageTotal": 0, + "deploymentsStorageTotal": 0, + "bucketsTotal": 0, + "executionsMbSecondsTotal": 0, + "buildsMbSecondsTotal": 0, + "databasesReadsTotal": 0, + "databasesWritesTotal": 0, + "requests": [], + "network": [], + "users": [], + "executions": [], + "executionsBreakdown": [], + "bucketsBreakdown": [], + "databasesStorageBreakdown": [], + "executionsMbSecondsBreakdown": [], + "buildsMbSecondsBreakdown": [], + "functionsStorageBreakdown": [], + "authPhoneTotal": 0, + "authPhoneEstimate": 0, + "authPhoneCountryBreakdown": [], + "databasesReads": [], + "databasesWrites": [], + "imageTransformations": [], + "imageTransformationsTotal": 0 + } }, "headers": { "description": "Headers", @@ -43364,7 +44629,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -43398,7 +44667,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "proxyRule": { "description": "Rule", @@ -43497,7 +44772,24 @@ "status", "logs", "renewAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "domain": "appwrite.company.com", + "type": "deployment", + "trigger": "manual", + "redirectUrl": "https:\/\/appwrite.io\/docs", + "redirectStatusCode": 301, + "deploymentId": "n3u9feiwmf", + "deploymentResourceType": "function", + "deploymentResourceId": "n3u9feiwmf", + "deploymentVcsProviderBranch": "function", + "status": "verified", + "logs": "HTTP challegne failed.", + "renewAt": "datetime" + } }, "smsTemplate": { "description": "SmsTemplate", @@ -43523,7 +44815,12 @@ "type", "locale", "message" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account." + } }, "emailTemplate": { "description": "EmailTemplate", @@ -43573,7 +44870,16 @@ "senderEmail", "replyTo", "subject" - ] + ], + "example": { + "type": "verification", + "locale": "en_us", + "message": "Click on the link to verify your account.", + "senderName": "My User", + "senderEmail": "mail@appwrite.io", + "replyTo": "emails@appwrite.io", + "subject": "Please verify your email address" + } }, "consoleVariables": { "description": "Console Variables", @@ -43661,7 +44967,22 @@ "_APP_DOMAIN_FUNCTIONS", "_APP_OPTIONS_FORCE_HTTPS", "_APP_DOMAINS_NAMESERVERS" - ] + ], + "example": { + "_APP_DOMAIN_TARGET_CNAME": "appwrite.io", + "_APP_DOMAIN_TARGET_A": "127.0.0.1", + "_APP_DOMAIN_TARGET_AAAA": "::1", + "_APP_STORAGE_LIMIT": "30000000", + "_APP_COMPUTE_SIZE_LIMIT": "30000000", + "_APP_USAGE_STATS": "enabled", + "_APP_VCS_ENABLED": true, + "_APP_DOMAIN_ENABLED": true, + "_APP_ASSISTANT_ENABLED": true, + "_APP_DOMAIN_SITES": "sites.localhost", + "_APP_DOMAIN_FUNCTIONS": "functions.localhost", + "_APP_OPTIONS_FORCE_HTTPS": "enabled", + "_APP_DOMAINS_NAMESERVERS": "ns1.example.com,ns2.example.com" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -43693,7 +45014,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -43713,7 +45040,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -43733,7 +45066,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -43765,7 +45102,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -43832,7 +45175,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -43943,7 +45301,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -44005,7 +45389,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -44080,7 +45474,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -44142,7 +45556,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } }, "migration": { "description": "Migration", @@ -44232,7 +45657,23 @@ "statusCounters", "resourceData", "errors" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "status": "pending", + "stage": "init", + "source": "Appwrite", + "destination": "Appwrite", + "resources": [ + "user" + ], + "resourceId": "databaseId:collectionId", + "statusCounters": "{\"Database\": {\"PENDING\": 0, \"SUCCESS\": 1, \"ERROR\": 0, \"SKIP\": 0, \"PROCESSING\": 0, \"WARNING\": 0}}", + "resourceData": "[{\"resource\":\"Database\",\"id\":\"public\",\"status\":\"SUCCESS\",\"message\":\"\"}]", + "errors": [] + } }, "migrationReport": { "description": "Migration Report", @@ -44302,7 +45743,18 @@ "function", "size", "version" - ] + ], + "example": { + "user": 20, + "team": 20, + "database": 20, + "document": 20, + "file": 20, + "bucket": 20, + "function": 20, + "size": 30000, + "version": "1.4.0" + } } }, "externalDocs": { diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index c67d26dd54..391adc2dfc 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -10763,7 +10763,7 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": null + "x-example": "" } } } @@ -25977,7 +25977,8 @@ "any": { "description": "Any", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": [] }, "documentList": { "description": "Documents List", @@ -26002,7 +26003,11 @@ "required": [ "total", "documents" - ] + ], + "example": { + "total": 5, + "documents": "" + } }, "collectionList": { "description": "Collections List", @@ -26027,7 +26032,11 @@ "required": [ "total", "collections" - ] + ], + "example": { + "total": 5, + "collections": "" + } }, "databaseList": { "description": "Databases List", @@ -26052,7 +26061,11 @@ "required": [ "total", "databases" - ] + ], + "example": { + "total": 5, + "databases": "" + } }, "indexList": { "description": "Indexes List", @@ -26077,7 +26090,11 @@ "required": [ "total", "indexes" - ] + ], + "example": { + "total": 5, + "indexes": "" + } }, "userList": { "description": "Users List", @@ -26102,7 +26119,11 @@ "required": [ "total", "users" - ] + ], + "example": { + "total": 5, + "users": "" + } }, "sessionList": { "description": "Sessions List", @@ -26127,7 +26148,11 @@ "required": [ "total", "sessions" - ] + ], + "example": { + "total": 5, + "sessions": "" + } }, "identityList": { "description": "Identities List", @@ -26152,7 +26177,11 @@ "required": [ "total", "identities" - ] + ], + "example": { + "total": 5, + "identities": "" + } }, "logList": { "description": "Logs List", @@ -26177,7 +26206,11 @@ "required": [ "total", "logs" - ] + ], + "example": { + "total": 5, + "logs": "" + } }, "fileList": { "description": "Files List", @@ -26202,7 +26235,11 @@ "required": [ "total", "files" - ] + ], + "example": { + "total": 5, + "files": "" + } }, "bucketList": { "description": "Buckets List", @@ -26227,7 +26264,11 @@ "required": [ "total", "buckets" - ] + ], + "example": { + "total": 5, + "buckets": "" + } }, "resourceTokenList": { "description": "Resource Tokens List", @@ -26252,7 +26293,11 @@ "required": [ "total", "tokens" - ] + ], + "example": { + "total": 5, + "tokens": "" + } }, "teamList": { "description": "Teams List", @@ -26277,7 +26322,11 @@ "required": [ "total", "teams" - ] + ], + "example": { + "total": 5, + "teams": "" + } }, "membershipList": { "description": "Memberships List", @@ -26302,7 +26351,11 @@ "required": [ "total", "memberships" - ] + ], + "example": { + "total": 5, + "memberships": "" + } }, "siteList": { "description": "Sites List", @@ -26327,7 +26380,11 @@ "required": [ "total", "sites" - ] + ], + "example": { + "total": 5, + "sites": "" + } }, "functionList": { "description": "Functions List", @@ -26352,7 +26409,11 @@ "required": [ "total", "functions" - ] + ], + "example": { + "total": 5, + "functions": "" + } }, "frameworkList": { "description": "Frameworks List", @@ -26377,7 +26438,11 @@ "required": [ "total", "frameworks" - ] + ], + "example": { + "total": 5, + "frameworks": "" + } }, "runtimeList": { "description": "Runtimes List", @@ -26402,7 +26467,11 @@ "required": [ "total", "runtimes" - ] + ], + "example": { + "total": 5, + "runtimes": "" + } }, "deploymentList": { "description": "Deployments List", @@ -26427,7 +26496,11 @@ "required": [ "total", "deployments" - ] + ], + "example": { + "total": 5, + "deployments": "" + } }, "executionList": { "description": "Executions List", @@ -26452,7 +26525,11 @@ "required": [ "total", "executions" - ] + ], + "example": { + "total": 5, + "executions": "" + } }, "countryList": { "description": "Countries List", @@ -26477,7 +26554,11 @@ "required": [ "total", "countries" - ] + ], + "example": { + "total": 5, + "countries": "" + } }, "continentList": { "description": "Continents List", @@ -26502,7 +26583,11 @@ "required": [ "total", "continents" - ] + ], + "example": { + "total": 5, + "continents": "" + } }, "languageList": { "description": "Languages List", @@ -26527,7 +26612,11 @@ "required": [ "total", "languages" - ] + ], + "example": { + "total": 5, + "languages": "" + } }, "currencyList": { "description": "Currencies List", @@ -26552,7 +26641,11 @@ "required": [ "total", "currencies" - ] + ], + "example": { + "total": 5, + "currencies": "" + } }, "phoneList": { "description": "Phones List", @@ -26577,7 +26670,11 @@ "required": [ "total", "phones" - ] + ], + "example": { + "total": 5, + "phones": "" + } }, "variableList": { "description": "Variables List", @@ -26602,7 +26699,11 @@ "required": [ "total", "variables" - ] + ], + "example": { + "total": 5, + "variables": "" + } }, "localeCodeList": { "description": "Locale codes list", @@ -26627,7 +26728,11 @@ "required": [ "total", "localeCodes" - ] + ], + "example": { + "total": 5, + "localeCodes": "" + } }, "providerList": { "description": "Provider list", @@ -26652,7 +26757,11 @@ "required": [ "total", "providers" - ] + ], + "example": { + "total": 5, + "providers": "" + } }, "messageList": { "description": "Message list", @@ -26677,7 +26786,11 @@ "required": [ "total", "messages" - ] + ], + "example": { + "total": 5, + "messages": "" + } }, "topicList": { "description": "Topic list", @@ -26702,7 +26815,11 @@ "required": [ "total", "topics" - ] + ], + "example": { + "total": 5, + "topics": "" + } }, "subscriberList": { "description": "Subscriber list", @@ -26727,7 +26844,11 @@ "required": [ "total", "subscribers" - ] + ], + "example": { + "total": 5, + "subscribers": "" + } }, "targetList": { "description": "Target list", @@ -26752,7 +26873,11 @@ "required": [ "total", "targets" - ] + ], + "example": { + "total": 5, + "targets": "" + } }, "specificationList": { "description": "Specifications List", @@ -26777,7 +26902,11 @@ "required": [ "total", "specifications" - ] + ], + "example": { + "total": 5, + "specifications": "" + } }, "database": { "description": "Database", @@ -26815,7 +26944,14 @@ "$createdAt", "$updatedAt", "enabled" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "name": "My Database", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "enabled": false + } }, "collection": { "description": "Collection", @@ -26926,7 +27062,21 @@ "documentSecurity", "attributes", "indexes" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "databaseId": "5e5ea5c16897e", + "name": "My Collection", + "enabled": false, + "documentSecurity": true, + "attributes": {}, + "indexes": {} + } }, "attributeList": { "description": "Attributes List", @@ -26981,7 +27131,11 @@ "required": [ "total", "attributes" - ] + ], + "example": { + "total": 5, + "attributes": "" + } }, "attributeString": { "description": "AttributeString", @@ -27056,7 +27210,20 @@ "$createdAt", "$updatedAt", "size" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "size": 128, + "default": "default", + "encrypt": false + } }, "attributeInteger": { "description": "AttributeInteger", @@ -27133,7 +27300,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "count", + "type": "integer", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1, + "max": 10, + "default": 10 + } }, "attributeFloat": { "description": "AttributeFloat", @@ -27210,7 +27390,20 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "percentageCompleted", + "type": "double", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "min": 1.5, + "max": 10.5, + "default": 2.5 + } }, "attributeBoolean": { "description": "AttributeBoolean", @@ -27272,7 +27465,18 @@ "required", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "isEnabled", + "type": "boolean", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "default": false + } }, "attributeEmail": { "description": "AttributeEmail", @@ -27340,7 +27544,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "userEmail", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "email", + "default": "default@example.com" + } }, "attributeEnum": { "description": "AttributeEnum", @@ -27417,7 +27633,20 @@ "$updatedAt", "elements", "format" - ] + ], + "example": { + "key": "status", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "elements": "element", + "format": "enum", + "default": "element" + } }, "attributeIp": { "description": "AttributeIP", @@ -27485,7 +27714,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "ipAddress", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "ip", + "default": "192.0.2.0" + } }, "attributeUrl": { "description": "AttributeURL", @@ -27553,7 +27794,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "githubUrl", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "url", + "default": "http:\/\/example.com" + } }, "attributeDatetime": { "description": "AttributeDatetime", @@ -27621,7 +27874,19 @@ "$createdAt", "$updatedAt", "format" - ] + ], + "example": { + "key": "birthDay", + "type": "datetime", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "format": "datetime", + "default": "2020-10-15T06:38:00.000+00:00" + } }, "attributeRelationship": { "description": "AttributeRelationship", @@ -27713,7 +27978,23 @@ "twoWayKey", "onDelete", "side" - ] + ], + "example": { + "key": "fullName", + "type": "string", + "status": "available", + "error": "string", + "required": true, + "array": false, + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "relatedCollection": "collection", + "relationType": "oneToOne|oneToMany|manyToOne|manyToMany", + "twoWay": false, + "twoWayKey": "string", + "onDelete": "restrict|cascade|setNull", + "side": "parent|child" + } }, "index": { "description": "Index", @@ -27785,7 +28066,18 @@ "lengths", "$createdAt", "$updatedAt" - ] + ], + "example": { + "key": "index1", + "type": "primary", + "status": "available", + "error": "string", + "attributes": [], + "lengths": [], + "orders": [], + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "document": { "description": "Document", @@ -27842,7 +28134,23 @@ "$createdAt", "$updatedAt", "$permissions" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$sequence": 1, + "$collectionId": "5e5ea5c15117e", + "$databaseId": "5e5ea5c15117e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "username": "john.doe", + "email": "john.doe@example.com", + "fullName": "John Doe", + "age": 30, + "isAdmin": false + } }, "log": { "description": "Log", @@ -27976,7 +28284,30 @@ "deviceModel", "countryCode", "countryName" - ] + ], + "example": { + "event": "account.sessions.create", + "userId": "610fc2f985ee0", + "userEmail": "john@appwrite.io", + "userName": "John Doe", + "mode": "admin", + "ip": "127.0.0.1", + "time": "2020-10-15T06:38:00.000+00:00", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States" + } }, "user": { "description": "User", @@ -28139,7 +28470,33 @@ "prefs", "targets", "accessedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "John Doe", + "password": "$argon2id$v=19$m=2048,t=4,p=3$aUZjLnliVWRINmFNTWMudg$5S+x+7uA31xFnrHFT47yFwcJeaP0w92L\/4LdgrVRXxE", + "hash": "argon2", + "hashOptions": {}, + "registration": "2020-10-15T06:38:00.000+00:00", + "status": true, + "labels": [ + "vip" + ], + "passwordUpdate": "2020-10-15T06:38:00.000+00:00", + "email": "john@appwrite.io", + "phone": "+4930901820", + "emailVerification": true, + "phoneVerification": true, + "mfa": true, + "prefs": { + "theme": "pink", + "timezone": "UTC" + }, + "targets": [], + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "algoMd5": { "description": "AlgoMD5", @@ -28153,7 +28510,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "md5" + } }, "algoSha": { "description": "AlgoSHA", @@ -28167,7 +28527,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "sha" + } }, "algoPhpass": { "description": "AlgoPHPass", @@ -28181,7 +28544,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "phpass" + } }, "algoBcrypt": { "description": "AlgoBcrypt", @@ -28195,7 +28561,10 @@ }, "required": [ "type" - ] + ], + "example": { + "type": "bcrypt" + } }, "algoScrypt": { "description": "AlgoScrypt", @@ -28237,7 +28606,14 @@ "costMemory", "costParallel", "length" - ] + ], + "example": { + "type": "scrypt", + "costCpu": 8, + "costMemory": 14, + "costParallel": 1, + "length": 64 + } }, "algoScryptModified": { "description": "AlgoScryptModified", @@ -28269,7 +28645,13 @@ "salt", "saltSeparator", "signerKey" - ] + ], + "example": { + "type": "scryptMod", + "salt": "UxLMreBr6tYyjQ==", + "saltSeparator": "Bw==", + "signerKey": "XyEKE9RcTDeLEsL\/RjwPDBv\/RqDl8fb3gpYEOQaPihbxf1ZAtSOHCjuAAa7Q3oHpCYhXSN9tizHgVOwn6krflQ==" + } }, "algoArgon2": { "description": "AlgoArgon2", @@ -28304,12 +28686,23 @@ "memoryCost", "timeCost", "threads" - ] + ], + "example": { + "type": "argon2", + "memoryCost": 65536, + "timeCost": 4, + "threads": 3 + } }, "preferences": { "description": "Preferences", "type": "object", - "additionalProperties": true + "additionalProperties": true, + "example": { + "language": "en", + "timezone": "UTC", + "darkTheme": true + } }, "session": { "description": "Session", @@ -28496,7 +28889,40 @@ "factors", "secret", "mfaUpdatedAt" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "expire": "2020-10-15T06:38:00.000+00:00", + "provider": "email", + "providerUid": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "ip": "127.0.0.1", + "osCode": "Mac", + "osName": "Mac", + "osVersion": "Mac", + "clientType": "browser", + "clientCode": "CM", + "clientName": "Chrome Mobile iOS", + "clientVersion": "84.0", + "clientEngine": "WebKit", + "clientEngineVersion": "605.1.15", + "deviceName": "smartphone", + "deviceBrand": "Google", + "deviceModel": "Nexus 5", + "countryCode": "US", + "countryName": "United States", + "current": true, + "factors": [ + "email" + ], + "secret": "5e5bb8c16897e", + "mfaUpdatedAt": "2020-10-15T06:38:00.000+00:00" + } }, "identity": { "description": "Identity", @@ -28564,7 +28990,19 @@ "providerAccessToken", "providerAccessTokenExpiry", "providerRefreshToken" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5bb8c16897e", + "provider": "email", + "providerUid": "5e5bb8c16897e", + "providerEmail": "user@example.com", + "providerAccessToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3", + "providerAccessTokenExpiry": "2020-10-15T06:38:00.000+00:00", + "providerRefreshToken": "MTQ0NjJkZmQ5OTM2NDE1ZTZjNGZmZjI3" + } }, "token": { "description": "Token", @@ -28608,7 +29046,15 @@ "secret", "expire", "phrase" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "secret": "", + "expire": "2020-10-15T06:38:00.000+00:00", + "phrase": "Golden Fox" + } }, "jwt": { "description": "JWT", @@ -28622,7 +29068,10 @@ }, "required": [ "jwt" - ] + ], + "example": { + "jwt": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" + } }, "locale": { "description": "Locale", @@ -28672,7 +29121,16 @@ "continent", "eu", "currency" - ] + ], + "example": { + "ip": "127.0.0.1", + "countryCode": "US", + "country": "United States", + "continentCode": "NA", + "continent": "North America", + "eu": false, + "currency": "USD" + } }, "localeCode": { "description": "LocaleCode", @@ -28692,7 +29150,11 @@ "required": [ "code", "name" - ] + ], + "example": { + "code": "en-us", + "name": "US" + } }, "file": { "description": "File", @@ -28774,7 +29236,22 @@ "sizeOriginal", "chunksTotal", "chunksUploaded" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "bucketId": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "name": "Pink.png", + "signature": "5d529fd02b544198ae075bd57c1762bb", + "mimeType": "image\/png", + "sizeOriginal": 17890, + "chunksTotal": 17890, + "chunksUploaded": 17890 + } }, "bucket": { "description": "Bucket", @@ -28866,7 +29343,26 @@ "compression", "encryption", "antivirus" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "read(\"any\")" + ], + "fileSecurity": true, + "name": "Documents", + "enabled": false, + "maximumFileSize": 100, + "allowedFileExtensions": [ + "jpg", + "png" + ], + "compression": "gzip", + "encryption": false, + "antivirus": false + } }, "resourceToken": { "description": "ResourceToken", @@ -28916,7 +29412,16 @@ "expire", "secret", "accessedAt" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "resourceId": "5e5ea5c168bb8:5e5ea5c168bb8", + "resourceType": "files", + "expire": "2020-10-15T06:38:00.000+00:00", + "secret": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", + "accessedAt": "2020-10-15T06:38:00.000+00:00" + } }, "team": { "description": "Team", @@ -28968,7 +29473,18 @@ "name", "total", "prefs" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "VIP", + "total": 7, + "prefs": { + "theme": "pink", + "timezone": "UTC" + } + } }, "membership": { "description": "Membership", @@ -29059,7 +29575,24 @@ "confirm", "mfa", "roles" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c16897e", + "userName": "John Doe", + "userEmail": "john@appwrite.io", + "teamId": "5e5ea5c16897e", + "teamName": "VIP", + "invited": "2020-10-15T06:38:00.000+00:00", + "joined": "2020-10-15T06:38:00.000+00:00", + "confirm": false, + "mfa": false, + "roles": [ + "owner" + ] + } }, "site": { "description": "Site", @@ -29246,7 +29779,38 @@ "buildRuntime", "adapter", "fallbackFile" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "My Site", + "enabled": false, + "live": false, + "logging": false, + "framework": "react", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "deploymentScreenshotLight": "5e5ea5c16897e", + "deploymentScreenshotDark": "5e5ea5c16897e", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "vars": [], + "timeout": 300, + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": "build", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "sites\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb", + "buildRuntime": "node-22", + "adapter": "static", + "fallbackFile": "index.html" + } }, "function": { "description": "Function", @@ -29436,7 +30000,37 @@ "providerRootDirectory", "providerSilentMode", "specification" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "execute": "users", + "name": "My Function", + "enabled": false, + "live": false, + "logging": false, + "runtime": "python-3.8", + "deploymentId": "5e5ea5c16897e", + "deploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentId": "5e5ea5c16897e", + "latestDeploymentCreatedAt": "2020-10-15T06:38:00.000+00:00", + "latestDeploymentStatus": "ready", + "scopes": "users.read", + "vars": [], + "events": "account.create", + "schedule": "5 4 * * *", + "timeout": 300, + "entrypoint": "index.js", + "commands": "npm install", + "version": "v2", + "installationId": "6m40at4ejk5h2u9s1hboo", + "providerRepositoryId": "appwrite", + "providerBranch": "main", + "providerRootDirectory": "functions\/helloWorld", + "providerSilentMode": false, + "specification": "s-1vcpu-512mb" + } }, "runtime": { "description": "Runtime", @@ -29495,7 +30089,17 @@ "image", "logo", "supports" - ] + ], + "example": { + "$id": "python-3.8", + "key": "python", + "name": "Python", + "version": "3.8", + "base": "python:3.8-alpine", + "image": "appwrite\\\/runtime-for-python:3.8", + "logo": "python.png", + "supports": "amd64" + } }, "framework": { "description": "Framework", @@ -29551,7 +30155,25 @@ "buildRuntime", "runtimes", "adapters" - ] + ], + "example": { + "key": "sveltekit", + "name": "SvelteKit", + "buildRuntime": "node-22", + "runtimes": [ + "static-1", + "node-22" + ], + "adapters": [ + { + "key": "static", + "buildRuntime": "node-22", + "buildCommand": "npm run build", + "installCommand": "npm install", + "outputDirectory": ".\/dist" + } + ] + } }, "frameworkAdapter": { "description": "Framework Adapter", @@ -29589,7 +30211,14 @@ "buildCommand", "outputDirectory", "fallbackFile" - ] + ], + "example": { + "key": "static", + "installCommand": "npm install", + "buildCommand": "npm run build", + "outputDirectory": ".\/dist", + "fallbackFile": "index.html" + } }, "deployment": { "description": "Deployment", @@ -29763,7 +30392,36 @@ "providerCommitMessage", "providerCommitUrl", "providerBranchUrl" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "type": "vcs", + "resourceId": "5e5ea6g16897e", + "resourceType": "functions", + "entrypoint": "index.js", + "sourceSize": 128, + "buildSize": 128, + "totalSize": 128, + "buildId": "5e5ea5c16897e", + "activate": true, + "screenshotLight": "5e5ea5c16897e", + "screenshotDark": "5e5ea5c16897e", + "status": "ready", + "buildLogs": "Compiling source files...", + "buildDuration": 128, + "providerRepositoryName": "database", + "providerRepositoryOwner": "utopia", + "providerRepositoryUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function", + "providerBranch": "0.7.x", + "providerCommitHash": "7c3f25d", + "providerCommitAuthorUrl": "https:\/\/github.com\/vermakhushboo", + "providerCommitAuthor": "Khushboo Verma", + "providerCommitMessage": "Update index.js", + "providerCommitUrl": "https:\/\/github.com\/vermakhushboo\/g4-node-function\/commit\/60c0416257a9cbcdd96b2d370c38d8f8d150ccfb", + "providerBranchUrl": "https:\/\/github.com\/vermakhushboo\/appwrite\/tree\/0.7.x" + } }, "execution": { "description": "Execution", @@ -29896,7 +30554,36 @@ "logs", "errors", "duration" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "$permissions": [ + "any" + ], + "functionId": "5e5ea6g16897e", + "trigger": "http", + "status": "processing", + "requestMethod": "GET", + "requestPath": "\/articles?id=5", + "requestHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "responseStatusCode": 200, + "responseBody": "", + "responseHeaders": [ + { + "Content-Type": "application\/json" + } + ], + "logs": "", + "errors": "", + "duration": 0.4, + "scheduledAt": "2020-10-15T06:38:00.000+00:00" + } }, "variable": { "description": "Variable", @@ -29952,7 +30639,17 @@ "secret", "resourceType", "resourceId" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "key": "API_KEY", + "value": "myPa$$word1", + "secret": false, + "resourceType": "function", + "resourceId": "myAwesomeFunction" + } }, "country": { "description": "Country", @@ -29972,7 +30669,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "United States", + "code": "US" + } }, "continent": { "description": "Continent", @@ -29992,7 +30693,11 @@ "required": [ "name", "code" - ] + ], + "example": { + "name": "Europe", + "code": "EU" + } }, "language": { "description": "Language", @@ -30018,7 +30723,12 @@ "name", "code", "nativeName" - ] + ], + "example": { + "name": "Italian", + "code": "it", + "nativeName": "Italiano" + } }, "currency": { "description": "Currency", @@ -30070,7 +30780,16 @@ "rounding", "code", "namePlural" - ] + ], + "example": { + "symbol": "$", + "name": "US dollar", + "symbolNative": "$", + "decimalDigits": 2, + "rounding": 0, + "code": "USD", + "namePlural": "US dollars" + } }, "phone": { "description": "Phone", @@ -30096,7 +30815,12 @@ "code", "countryCode", "countryName" - ] + ], + "example": { + "code": "+1", + "countryCode": "US", + "countryName": "United States" + } }, "healthAntivirus": { "description": "Health Antivirus", @@ -30116,7 +30840,11 @@ "required": [ "version", "status" - ] + ], + "example": { + "version": "1.0.0", + "status": "online" + } }, "healthQueue": { "description": "Health Queue", @@ -30131,7 +30859,10 @@ }, "required": [ "size" - ] + ], + "example": { + "size": 8 + } }, "healthStatus": { "description": "Health Status", @@ -30158,7 +30889,12 @@ "name", "ping", "status" - ] + ], + "example": { + "name": "database", + "ping": 128, + "status": "pass" + } }, "healthCertificate": { "description": "Health Certificate", @@ -30202,7 +30938,15 @@ "validFrom", "validTo", "signatureTypeSN" - ] + ], + "example": { + "name": "\/CN=www.google.com", + "subjectSN": "", + "issuerOrganisation": "", + "validFrom": "1704200998", + "validTo": "1711458597", + "signatureTypeSN": "RSA-SHA256" + } }, "healthTime": { "description": "Health Time", @@ -30231,7 +30975,12 @@ "remoteTime", "localTime", "diff" - ] + ], + "example": { + "remoteTime": 1639490751, + "localTime": 1639490844, + "diff": 93 + } }, "headers": { "description": "Headers", @@ -30251,7 +31000,11 @@ "required": [ "name", "value" - ] + ], + "example": { + "name": "Content-Type", + "value": "application\/json" + } }, "specification": { "description": "Specification", @@ -30285,7 +31038,13 @@ "cpus", "enabled", "slug" - ] + ], + "example": { + "memory": 512, + "cpus": 1, + "enabled": true, + "slug": "s-1vcpu-512mb" + } }, "mfaChallenge": { "description": "MFA Challenge", @@ -30317,7 +31076,13 @@ "$createdAt", "userId", "expire" - ] + ], + "example": { + "$id": "bb8ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "userId": "5e5ea5c168bb8", + "expire": "2020-10-15T06:38:00.000+00:00" + } }, "mfaRecoveryCodes": { "description": "MFA Recovery Codes", @@ -30337,7 +31102,13 @@ }, "required": [ "recoveryCodes" - ] + ], + "example": { + "recoveryCodes": [ + "a3kf0-s0cl2", + "s0co1-as98s" + ] + } }, "mfaType": { "description": "MFAType", @@ -30357,7 +31128,11 @@ "required": [ "secret", "uri" - ] + ], + "example": { + "secret": true, + "uri": true + } }, "mfaFactors": { "description": "MFAFactors", @@ -30389,7 +31164,13 @@ "phone", "email", "recoveryCode" - ] + ], + "example": { + "totp": true, + "phone": true, + "email": true, + "recoveryCode": true + } }, "provider": { "description": "Provider", @@ -30456,7 +31237,22 @@ "enabled", "type", "credentials" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Mailgun", + "provider": "mailgun", + "enabled": true, + "type": "sms", + "credentials": { + "key": "123456789" + }, + "options": { + "from": "sender-email@mydomain" + } + } }, "message": { "description": "Message", @@ -30567,7 +31363,33 @@ "deliveredTotal", "data", "status" - ] + ], + "example": { + "$id": "5e5ea5c16897e", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "topics": [ + "5e5ea5c16897e" + ], + "users": [ + "5e5ea5c16897e" + ], + "targets": [ + "5e5ea5c16897e" + ], + "scheduledAt": "2020-10-15T06:38:00.000+00:00", + "deliveredAt": "2020-10-15T06:38:00.000+00:00", + "deliveryErrors": [ + "Failed to send message to target 5e5ea5c16897e: Credentials not valid." + ], + "deliveredTotal": 1, + "data": { + "subject": "Welcome to Appwrite", + "content": "Hi there, welcome to Appwrite family." + }, + "status": "Message status can be one of the following: draft, processing, scheduled, sent, or failed." + } }, "topic": { "description": "Topic", @@ -30629,7 +31451,17 @@ "smsTotal", "pushTotal", "subscribe" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "events", + "emailTotal": 100, + "smsTotal": 100, + "pushTotal": 100, + "subscribe": "users" + } }, "subscriber": { "description": "Subscriber", @@ -30704,7 +31536,27 @@ "userName", "topicId", "providerType" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "targetId": "259125845563242502", + "target": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "providerType": "email", + "providerId": "259125845563242502", + "name": "ageon-app-email", + "identifier": "random-mail@email.org", + "userId": "5e5ea5c16897e" + }, + "userId": "5e5ea5c16897e", + "userName": "Aegon Targaryen", + "topicId": "259125845563242502", + "providerType": "email" + } }, "target": { "description": "Target", @@ -30766,7 +31618,18 @@ "providerType", "identifier", "expired" - ] + ], + "example": { + "$id": "259125845563242502", + "$createdAt": "2020-10-15T06:38:00.000+00:00", + "$updatedAt": "2020-10-15T06:38:00.000+00:00", + "name": "Apple iPhone 12", + "userId": "259125845563242502", + "providerId": "259125845563242502", + "providerType": "email", + "identifier": "token", + "expired": false + } } }, "externalDocs": { diff --git a/app/controllers/api/avatars.php b/app/controllers/api/avatars.php index 3a7b4aa582..785324739b 100644 --- a/app/controllers/api/avatars.php +++ b/app/controllers/api/avatars.php @@ -10,6 +10,7 @@ use Appwrite\URL\URL as URLParse; use Appwrite\Utopia\Response; use chillerlan\QRCode\QRCode; use chillerlan\QRCode\QROptions; +use enshrined\svgSanitize\Sanitizer as SvgSanitizer; use Utopia\App; use Utopia\Config\Config; use Utopia\Database\Database; @@ -362,7 +363,8 @@ App::get('/v1/avatars/favicon') $client = new Client(); try { $res = $client - ->setAllowRedirects(false) + ->setAllowRedirects(true) + ->setMaxRedirects(5) ->setUserAgent(\sprintf( APP_USERAGENT, System::getEnv('_APP_VERSION', 'UNKNOWN'), @@ -373,15 +375,11 @@ App::get('/v1/avatars/favicon') throw new Exception(Exception::AVATAR_REMOTE_URL_FAILED); } - if ($res->getStatusCode() !== 200) { - throw new Exception(Exception::AVATAR_REMOTE_URL_FAILED); - } - $doc = new DOMDocument(); $doc->strictErrorChecking = false; @$doc->loadHTML($res->getBody()); - $links = $doc->getElementsByTagName('link'); + $links = $doc->getElementsByTagName('link') ?? []; $outputHref = ''; $outputExt = ''; $space = 0; @@ -399,6 +397,12 @@ App::get('/v1/avatars/favicon') $ext = \pathinfo(\parse_url($absolute, PHP_URL_PATH), PATHINFO_EXTENSION); switch ($ext) { + case 'svg': + // SVG icons are prioritized by assigning the maximum possible value. + $space = PHP_INT_MAX; + $outputHref = $absolute; + $outputExt = $ext; + break; case 'ico': case 'png': case 'jpg': @@ -437,7 +441,8 @@ App::get('/v1/avatars/favicon') $client = new Client(); try { $res = $client - ->setAllowRedirects(false) + ->setAllowRedirects(true) + ->setMaxRedirects(5) ->fetch($outputHref); } catch (\Throwable) { throw new Exception(Exception::AVATAR_REMOTE_URL_FAILED); @@ -449,14 +454,33 @@ App::get('/v1/avatars/favicon') $data = $res->getBody(); - if ('ico' == $outputExt) { // Skip crop, Imagick isn\'t supporting icon files - if (empty($data) || (\mb_substr($data, 0, 5) === 'addHeader('Cache-Control', 'private, max-age=2592000') // 30 days ->setContentType('image/x-icon') ->file($data); + return; + } + + if ('svg' === $outputExt) { // Skip crop, Imagick isn\'t supporting svg files + $sanitizer = new SvgSanitizer(); + $sanitizer->minify(true); + $cleanSvg = $sanitizer->sanitize($data); + if ($cleanSvg === false) { + throw new \Exception('SVG sanitization failed'); + } + $response + ->addHeader('Cache-Control', 'private, max-age=2592000') // 30 days + ->setContentType('image/svg+xml') + ->file($cleanSvg); + return; } $image = new Image($data); diff --git a/app/controllers/general.php b/app/controllers/general.php index 42e26b6fbe..d5b0979441 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -1380,9 +1380,10 @@ App::get('/robots.txt') ->inject('apiKey') ->action(function (App $utopia, SwooleRequest $swooleRequest, Request $request, Response $response, Log $log, Database $dbForPlatform, callable $getProjectDB, Event $queueForEvents, StatsUsage $queueForStatsUsage, Func $queueForFunctions, Executor $executor, Reader $geodb, callable $isResourceBlocked, string $previewHostname, ?Key $apiKey) { $host = $request->getHostname() ?? ''; + $consoleDomain = System::getEnv('_APP_CONSOLE_DOMAIN', ''); $mainDomain = System::getEnv('_APP_DOMAIN', ''); - if (($host === $mainDomain || $host === 'localhost') && empty($previewHostname)) { + if (($host === $consoleDomain || $host === $mainDomain || $host === 'localhost') && empty($previewHostname)) { $template = new View(__DIR__ . '/../views/general/robots.phtml'); $response->text($template->render(false)); } else { @@ -1413,9 +1414,10 @@ App::get('/humans.txt') ->inject('apiKey') ->action(function (App $utopia, SwooleRequest $swooleRequest, Request $request, Response $response, Log $log, Database $dbForPlatform, callable $getProjectDB, Event $queueForEvents, StatsUsage $queueForStatsUsage, Func $queueForFunctions, Executor $executor, Reader $geodb, callable $isResourceBlocked, string $previewHostname, ?Key $apiKey) { $host = $request->getHostname() ?? ''; + $consoleDomain = System::getEnv('_APP_CONSOLE_DOMAIN', ''); $mainDomain = System::getEnv('_APP_DOMAIN', ''); - if (($host === $mainDomain || $host === 'localhost') && empty($previewHostname)) { + if (($host === $consoleDomain || $host === $mainDomain || $host === 'localhost') && empty($previewHostname)) { $template = new View(__DIR__ . '/../views/general/humans.phtml'); $response->text($template->render(false)); } else { diff --git a/app/controllers/shared/api.php b/app/controllers/shared/api.php index 86fb1e5822..2ef992764f 100644 --- a/app/controllers/shared/api.php +++ b/app/controllers/shared/api.php @@ -31,6 +31,7 @@ use Utopia\Database\Helpers\Role; use Utopia\Database\Validator\Authorization; use Utopia\Queue\Publisher; use Utopia\System\System; +use Utopia\Telemetry\Adapter as Telemetry; use Utopia\Validator\WhiteList; $parseLabel = function (string $label, array $responsePayload, array $requestParams, Document $user) { @@ -421,7 +422,8 @@ App::init() ->inject('apiKey') ->inject('plan') ->inject('devKey') - ->action(function (App $utopia, Request $request, Response $response, Document $project, Document $user, Publisher $publisher, Event $queueForEvents, Messaging $queueForMessaging, Audit $queueForAudits, Delete $queueForDeletes, EventDatabase $queueForDatabase, Build $queueForBuilds, StatsUsage $queueForStatsUsage, Database $dbForProject, callable $timelimit, Document $resourceToken, string $mode, ?Key $apiKey, array $plan, Document $devKey) use ($usageDatabaseListener, $eventDatabaseListener) { + ->inject('telemetry') + ->action(function (App $utopia, Request $request, Response $response, Document $project, Document $user, Publisher $publisher, Event $queueForEvents, Messaging $queueForMessaging, Audit $queueForAudits, Delete $queueForDeletes, EventDatabase $queueForDatabase, Build $queueForBuilds, StatsUsage $queueForStatsUsage, Database $dbForProject, callable $timelimit, Document $resourceToken, string $mode, ?Key $apiKey, array $plan, Document $devKey, Telemetry $telemetry) use ($usageDatabaseListener, $eventDatabaseListener) { $route = $utopia->getRoute(); @@ -554,6 +556,7 @@ App::init() )); $useCache = $route->getLabel('cache', false); + $storageCacheOperationsCounter = $telemetry->createCounter('storage.cache.operations.load'); if ($useCache) { $route = $utopia->match($request); $isImageTransformation = $route->getPath() === '/v1/storage/buckets/:bucketId/files/:fileId/preview'; @@ -619,10 +622,12 @@ App::init() ->addHeader('Cache-Control', sprintf('private, max-age=%d', $timestamp)) ->addHeader('X-Appwrite-Cache', 'hit') ->setContentType($cacheLog->getAttribute('mimeType')); + $storageCacheOperationsCounter->add(1, ['result' => 'hit']); if (!$isImageTransformation || !$isDisabled) { $response->send($data); } } else { + $storageCacheOperationsCounter->add(1, ['result' => 'miss']); $response ->addHeader('Cache-Control', 'no-cache, no-store, must-revalidate') ->addHeader('Pragma', 'no-cache') diff --git a/composer.json b/composer.json index 31a31af9f2..73cdcc3d86 100644 --- a/composer.json +++ b/composer.json @@ -82,7 +82,8 @@ "adhocore/jwt": "1.1.*", "spomky-labs/otphp": "^10.0", "webonyx/graphql-php": "14.11.*", - "league/csv": "9.14.*" + "league/csv": "9.14.*", + "enshrined/svg-sanitize": "0.21.*" }, "require-dev": { "ext-fileinfo": "*", diff --git a/composer.lock b/composer.lock index da084c8fcd..e3b3d2208f 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "edbe5912c45e1f467f398541a75a77de", + "content-hash": "7b2ef6192403daf5c492219822ce0aa1", "packages": [ { "name": "adhocore/jwt", @@ -69,16 +69,16 @@ }, { "name": "appwrite/appwrite", - "version": "15.0.0", + "version": "15.1.0", "source": { "type": "git", "url": "https://github.com/appwrite/sdk-for-php.git", - "reference": "deb97b62e0abed8a4fd5c5d48e77365cf89867cf" + "reference": "c438b3885071ac7c0329199dce5e6f6a24dd215b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/appwrite/sdk-for-php/zipball/deb97b62e0abed8a4fd5c5d48e77365cf89867cf", - "reference": "deb97b62e0abed8a4fd5c5d48e77365cf89867cf", + "url": "https://api.github.com/repos/appwrite/sdk-for-php/zipball/c438b3885071ac7c0329199dce5e6f6a24dd215b", + "reference": "c438b3885071ac7c0329199dce5e6f6a24dd215b", "shasum": "" }, "require": { @@ -104,10 +104,10 @@ "support": { "email": "team@appwrite.io", "issues": "https://github.com/appwrite/sdk-for-php/issues", - "source": "https://github.com/appwrite/sdk-for-php/tree/15.0.0", + "source": "https://github.com/appwrite/sdk-for-php/tree/15.1.0", "url": "https://appwrite.io/support" }, - "time": "2025-05-18T09:47:10+00:00" + "time": "2025-08-01T04:50:51+00:00" }, { "name": "appwrite/php-clamav", @@ -628,6 +628,51 @@ ], "time": "2023-08-10T19:36:49+00:00" }, + { + "name": "enshrined/svg-sanitize", + "version": "0.21.0", + "source": { + "type": "git", + "url": "https://github.com/darylldoyle/svg-sanitizer.git", + "reference": "5e477468fac5c5ce933dce53af3e8e4e58dcccc9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/darylldoyle/svg-sanitizer/zipball/5e477468fac5c5ce933dce53af3e8e4e58dcccc9", + "reference": "5e477468fac5c5ce933dce53af3e8e4e58dcccc9", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "php": "^7.1 || ^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^6.5 || ^8.5" + }, + "type": "library", + "autoload": { + "psr-4": { + "enshrined\\svgSanitize\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "Daryll Doyle", + "email": "daryll@enshrined.co.uk" + } + ], + "description": "An SVG sanitizer for PHP", + "support": { + "issues": "https://github.com/darylldoyle/svg-sanitizer/issues", + "source": "https://github.com/darylldoyle/svg-sanitizer/tree/0.21.0" + }, + "time": "2025-01-13T09:32:25+00:00" + }, { "name": "giggsey/libphonenumber-for-php-lite", "version": "8.13.36", @@ -3497,16 +3542,16 @@ }, { "name": "utopia-php/database", - "version": "0.71.10", + "version": "0.71.11", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "83278d663f9c63c25a11d9e71c7922da7ec48636" + "reference": "644ed827aace63cbdf8c6c64a3998c11b43e3383" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/83278d663f9c63c25a11d9e71c7922da7ec48636", - "reference": "83278d663f9c63c25a11d9e71c7922da7ec48636", + "url": "https://api.github.com/repos/utopia-php/database/zipball/644ed827aace63cbdf8c6c64a3998c11b43e3383", + "reference": "644ed827aace63cbdf8c6c64a3998c11b43e3383", "shasum": "" }, "require": { @@ -3547,9 +3592,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/0.71.10" + "source": "https://github.com/utopia-php/database/tree/0.71.11" }, - "time": "2025-07-18T00:05:55+00:00" + "time": "2025-08-05T08:35:29+00:00" }, { "name": "utopia-php/detector", @@ -4814,16 +4859,16 @@ "packages-dev": [ { "name": "appwrite/sdk-generator", - "version": "0.41.27", + "version": "0.41.28", "source": { "type": "git", "url": "https://github.com/appwrite/sdk-generator.git", - "reference": "083fd2e8163d6a4e59ee971ac6cb97277d831dd5" + "reference": "8eace11070264c62c8da3c69498fb8dc98fcfaf7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/083fd2e8163d6a4e59ee971ac6cb97277d831dd5", - "reference": "083fd2e8163d6a4e59ee971ac6cb97277d831dd5", + "url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/8eace11070264c62c8da3c69498fb8dc98fcfaf7", + "reference": "8eace11070264c62c8da3c69498fb8dc98fcfaf7", "shasum": "" }, "require": { @@ -4859,9 +4904,9 @@ "description": "Appwrite PHP library for generating API SDKs for multiple programming languages and platforms", "support": { "issues": "https://github.com/appwrite/sdk-generator/issues", - "source": "https://github.com/appwrite/sdk-generator/tree/0.41.27" + "source": "https://github.com/appwrite/sdk-generator/tree/0.41.28" }, - "time": "2025-07-31T10:20:46+00:00" + "time": "2025-08-01T11:06:30+00:00" }, { "name": "doctrine/annotations", @@ -5280,16 +5325,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.13.3", + "version": "1.13.4", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "faed855a7b5f4d4637717c2b3863e277116beb36" + "reference": "07d290f0c47959fd5eed98c95ee5602db07e0b6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/faed855a7b5f4d4637717c2b3863e277116beb36", - "reference": "faed855a7b5f4d4637717c2b3863e277116beb36", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/07d290f0c47959fd5eed98c95ee5602db07e0b6a", + "reference": "07d290f0c47959fd5eed98c95ee5602db07e0b6a", "shasum": "" }, "require": { @@ -5328,7 +5373,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.13.3" + "source": "https://github.com/myclabs/DeepCopy/tree/1.13.4" }, "funding": [ { @@ -5336,7 +5381,7 @@ "type": "tidelift" } ], - "time": "2025-07-05T12:25:42+00:00" + "time": "2025-08-01T08:46:24+00:00" }, { "name": "nikic/php-parser", diff --git a/src/Appwrite/SDK/Specification/Format/OpenAPI3.php b/src/Appwrite/SDK/Specification/Format/OpenAPI3.php index c3d70fa7a2..c4a39b707b 100644 --- a/src/Appwrite/SDK/Specification/Format/OpenAPI3.php +++ b/src/Appwrite/SDK/Specification/Format/OpenAPI3.php @@ -603,6 +603,7 @@ class OpenAPI3 extends Format $required = $model->getRequired(); $rules = $model->getRules(); + $examples = []; $output['components']['schemas'][$model->getType()] = [ 'description' => $model->getName(), @@ -626,6 +627,8 @@ class OpenAPI3 extends Format $format = null; $items = null; + $examples[$name] = $rule['example'] ?? null; + switch ($rule['type']) { case 'string': case 'datetime': @@ -714,6 +717,12 @@ class OpenAPI3 extends Format $output['components']['schemas'][$model->getType()]['properties'][$name]['nullable'] = true; } } + + if ($model->isAny() && !empty($model->getSampleData())) { + $examples = array_merge($examples, $model->getSampleData()); + } + + $output['components']['schemas'][$model->getType()]['example'] = $examples; } \ksort($output['paths']); diff --git a/src/Appwrite/SDK/Specification/Format/Swagger2.php b/src/Appwrite/SDK/Specification/Format/Swagger2.php index 10acca933f..45fdc63bc8 100644 --- a/src/Appwrite/SDK/Specification/Format/Swagger2.php +++ b/src/Appwrite/SDK/Specification/Format/Swagger2.php @@ -610,6 +610,7 @@ class Swagger2 extends Format $required = $model->getRequired(); $rules = $model->getRules(); + $examples = []; $output['definitions'][$model->getType()] = [ 'description' => $model->getName(), @@ -633,6 +634,8 @@ class Swagger2 extends Format $format = null; $items = null; + $examples[$name] = $rule['example'] ?? null; + switch ($rule['type']) { case 'string': case 'datetime': @@ -730,6 +733,12 @@ class Swagger2 extends Format $output['definitions'][$model->getType()]['properties'][$name]['x-nullable'] = true; } } + + if ($model->isAny() && !empty($model->getSampleData())) { + $examples = array_merge($examples, $model->getSampleData()); + } + + $output['definitions'][$model->getType()]['example'] = $examples; } \ksort($output['paths']); diff --git a/src/Appwrite/Utopia/Response/Model/Any.php b/src/Appwrite/Utopia/Response/Model/Any.php index 634e0859b9..6863748ac8 100644 --- a/src/Appwrite/Utopia/Response/Model/Any.php +++ b/src/Appwrite/Utopia/Response/Model/Any.php @@ -31,4 +31,14 @@ class Any extends Model { return Response::MODEL_ANY; } + + /** + * Get sample data + * + * @return array + */ + public function getSampleData(): array + { + return []; + } } diff --git a/src/Appwrite/Utopia/Response/Model/Document.php b/src/Appwrite/Utopia/Response/Model/Document.php index c36d6de12e..dc9faf6a8e 100644 --- a/src/Appwrite/Utopia/Response/Model/Document.php +++ b/src/Appwrite/Utopia/Response/Model/Document.php @@ -95,4 +95,15 @@ class Document extends Any return $document; } + + public function getSampleData(): array + { + return [ + 'username' => 'john.doe', + 'email' => 'john.doe@example.com', + 'fullName' => 'John Doe', + 'age' => 30, + 'isAdmin' => false, + ]; + } } diff --git a/src/Appwrite/Utopia/Response/Model/Preferences.php b/src/Appwrite/Utopia/Response/Model/Preferences.php index 379543660c..e40ca6bfda 100644 --- a/src/Appwrite/Utopia/Response/Model/Preferences.php +++ b/src/Appwrite/Utopia/Response/Model/Preferences.php @@ -25,4 +25,13 @@ class Preferences extends Any { return Response::MODEL_PREFERENCES; } + + public function getSampleData(): array + { + return [ + 'language' => 'en', + 'timezone' => 'UTC', + 'darkTheme' => true, + ]; + } } diff --git a/tests/e2e/Services/Avatars/AvatarsBase.php b/tests/e2e/Services/Avatars/AvatarsBase.php index ba66920ed6..6d34418438 100644 --- a/tests/e2e/Services/Avatars/AvatarsBase.php +++ b/tests/e2e/Services/Avatars/AvatarsBase.php @@ -284,7 +284,17 @@ trait AvatarsBase ]); $this->assertEquals(200, $response['headers']['status-code']); - $this->assertEquals('image/x-icon', $response['headers']['content-type']); + $this->assertEquals('image/svg+xml', $response['headers']['content-type']); + $this->assertNotEmpty($response['body']); + + $response = $this->client->call(Client::METHOD_GET, '/avatars/favicon', [ + 'x-appwrite-project' => $this->getProject()['$id'], + ], [ + 'url' => 'https://appwrite.io/', + ]); + + $this->assertEquals(200, $response['headers']['status-code']); + $this->assertEquals('image/svg+xml', $response['headers']['content-type']); $this->assertNotEmpty($response['body']); /** diff --git a/tests/e2e/Services/Databases/DatabasesBase.php b/tests/e2e/Services/Databases/DatabasesBase.php index de5d33f29d..9b3e31dd70 100644 --- a/tests/e2e/Services/Databases/DatabasesBase.php +++ b/tests/e2e/Services/Databases/DatabasesBase.php @@ -5664,7 +5664,27 @@ trait DatabasesBase ]), ['min' => 7]); $this->assertEquals(400, $err['headers']['status-code']); - // Test type error on non-numeric attribut + // Test min limit exceeded with custom value + $err = $this->client->call(Client::METHOD_PATCH, '/databases/' . $databaseId . '/collections/' . $collectionId . '/documents/' . $documentId . '/count/decrement', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ]), [ + 'value' => 3, + 'min' => 5, + ]); + $this->assertEquals(400, $err['headers']['status-code']); + + // Test min limit 0 + $err = $this->client->call(Client::METHOD_PATCH, '/databases/' . $databaseId . '/collections/' . $collectionId . '/documents/' . $documentId . '/count/decrement', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ]), [ + 'value' => 10, + 'min' => 0, + ]); + $this->assertEquals(400, $err['headers']['status-code']); + + // Test type error on non-numeric attribute $typeErr = $this->client->call(Client::METHOD_PATCH, '/databases/' . $databaseId . '/collections/' . $collectionId . '/documents/' . $documentId . '/count/decrement', array_merge([ 'content-type' => 'application/json', 'x-appwrite-project' => $this->getProject()['$id'],