appwrite 8.0.0 → 9.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/appwrite/client.rb +4 -4
- data/lib/appwrite/models/attribute_boolean.rb +5 -0
- data/lib/appwrite/models/attribute_datetime.rb +5 -0
- data/lib/appwrite/models/attribute_email.rb +5 -0
- data/lib/appwrite/models/attribute_enum.rb +5 -0
- data/lib/appwrite/models/attribute_float.rb +5 -0
- data/lib/appwrite/models/attribute_integer.rb +5 -0
- data/lib/appwrite/models/attribute_ip.rb +5 -0
- data/lib/appwrite/models/attribute_relationship.rb +5 -0
- data/lib/appwrite/models/attribute_string.rb +5 -0
- data/lib/appwrite/models/attribute_url.rb +5 -0
- data/lib/appwrite/models/database.rb +8 -3
- data/lib/appwrite/models/deployment.rb +63 -13
- data/lib/appwrite/models/execution.rb +40 -20
- data/lib/appwrite/models/function.rb +53 -13
- data/lib/appwrite/models/headers.rb +32 -0
- data/lib/appwrite/models/health_status.rb +5 -0
- data/lib/appwrite/models/identity.rb +72 -0
- data/lib/appwrite/models/identity_list.rb +32 -0
- data/lib/appwrite/models/index.rb +5 -0
- data/lib/appwrite/models/locale_code.rb +32 -0
- data/lib/appwrite/models/locale_code_list.rb +32 -0
- data/lib/appwrite/models/user.rb +13 -3
- data/lib/appwrite/models/variable.rb +10 -5
- data/lib/appwrite/role.rb +56 -0
- data/lib/appwrite/services/account.rb +185 -130
- data/lib/appwrite/services/avatars.rb +42 -42
- data/lib/appwrite/services/databases.rb +274 -262
- data/lib/appwrite/services/functions.rb +229 -143
- data/lib/appwrite/services/graphql.rb +12 -12
- data/lib/appwrite/services/health.rb +111 -62
- data/lib/appwrite/services/locale.rb +67 -42
- data/lib/appwrite/services/storage.rb +85 -83
- data/lib/appwrite/services/teams.rb +80 -79
- data/lib/appwrite/services/users.rb +248 -150
- data/lib/appwrite.rb +5 -0
- metadata +7 -2
@@ -24,28 +24,28 @@ module Appwrite
|
|
24
24
|
#
|
25
25
|
# @return []
|
26
26
|
def get_browser(code:, width: nil, height: nil, quality: nil)
|
27
|
-
|
27
|
+
api_path = '/avatars/browsers/{code}'
|
28
28
|
.gsub('{code}', code)
|
29
29
|
|
30
30
|
if code.nil?
|
31
31
|
raise Appwrite::Exception.new('Missing required parameter: "code"')
|
32
32
|
end
|
33
33
|
|
34
|
-
|
34
|
+
api_params = {
|
35
35
|
width: width,
|
36
36
|
height: height,
|
37
37
|
quality: quality,
|
38
38
|
}
|
39
39
|
|
40
|
-
|
40
|
+
api_headers = {
|
41
41
|
"content-type": 'application/json',
|
42
42
|
}
|
43
43
|
|
44
44
|
@client.call(
|
45
45
|
method: 'GET',
|
46
|
-
path:
|
47
|
-
headers:
|
48
|
-
params:
|
46
|
+
path: api_path,
|
47
|
+
headers: api_headers,
|
48
|
+
params: api_params,
|
49
49
|
)
|
50
50
|
end
|
51
51
|
|
@@ -67,28 +67,28 @@ module Appwrite
|
|
67
67
|
#
|
68
68
|
# @return []
|
69
69
|
def get_credit_card(code:, width: nil, height: nil, quality: nil)
|
70
|
-
|
70
|
+
api_path = '/avatars/credit-cards/{code}'
|
71
71
|
.gsub('{code}', code)
|
72
72
|
|
73
73
|
if code.nil?
|
74
74
|
raise Appwrite::Exception.new('Missing required parameter: "code"')
|
75
75
|
end
|
76
76
|
|
77
|
-
|
77
|
+
api_params = {
|
78
78
|
width: width,
|
79
79
|
height: height,
|
80
80
|
quality: quality,
|
81
81
|
}
|
82
82
|
|
83
|
-
|
83
|
+
api_headers = {
|
84
84
|
"content-type": 'application/json',
|
85
85
|
}
|
86
86
|
|
87
87
|
@client.call(
|
88
88
|
method: 'GET',
|
89
|
-
path:
|
90
|
-
headers:
|
91
|
-
params:
|
89
|
+
path: api_path,
|
90
|
+
headers: api_headers,
|
91
|
+
params: api_params,
|
92
92
|
)
|
93
93
|
end
|
94
94
|
|
@@ -101,25 +101,25 @@ module Appwrite
|
|
101
101
|
#
|
102
102
|
# @return []
|
103
103
|
def get_favicon(url:)
|
104
|
-
|
104
|
+
api_path = '/avatars/favicon'
|
105
105
|
|
106
106
|
if url.nil?
|
107
107
|
raise Appwrite::Exception.new('Missing required parameter: "url"')
|
108
108
|
end
|
109
109
|
|
110
|
-
|
110
|
+
api_params = {
|
111
111
|
url: url,
|
112
112
|
}
|
113
113
|
|
114
|
-
|
114
|
+
api_headers = {
|
115
115
|
"content-type": 'application/json',
|
116
116
|
}
|
117
117
|
|
118
118
|
@client.call(
|
119
119
|
method: 'GET',
|
120
|
-
path:
|
121
|
-
headers:
|
122
|
-
params:
|
120
|
+
path: api_path,
|
121
|
+
headers: api_headers,
|
122
|
+
params: api_params,
|
123
123
|
)
|
124
124
|
end
|
125
125
|
|
@@ -142,28 +142,28 @@ module Appwrite
|
|
142
142
|
#
|
143
143
|
# @return []
|
144
144
|
def get_flag(code:, width: nil, height: nil, quality: nil)
|
145
|
-
|
145
|
+
api_path = '/avatars/flags/{code}'
|
146
146
|
.gsub('{code}', code)
|
147
147
|
|
148
148
|
if code.nil?
|
149
149
|
raise Appwrite::Exception.new('Missing required parameter: "code"')
|
150
150
|
end
|
151
151
|
|
152
|
-
|
152
|
+
api_params = {
|
153
153
|
width: width,
|
154
154
|
height: height,
|
155
155
|
quality: quality,
|
156
156
|
}
|
157
157
|
|
158
|
-
|
158
|
+
api_headers = {
|
159
159
|
"content-type": 'application/json',
|
160
160
|
}
|
161
161
|
|
162
162
|
@client.call(
|
163
163
|
method: 'GET',
|
164
|
-
path:
|
165
|
-
headers:
|
166
|
-
params:
|
164
|
+
path: api_path,
|
165
|
+
headers: api_headers,
|
166
|
+
params: api_params,
|
167
167
|
)
|
168
168
|
end
|
169
169
|
|
@@ -185,27 +185,27 @@ module Appwrite
|
|
185
185
|
#
|
186
186
|
# @return []
|
187
187
|
def get_image(url:, width: nil, height: nil)
|
188
|
-
|
188
|
+
api_path = '/avatars/image'
|
189
189
|
|
190
190
|
if url.nil?
|
191
191
|
raise Appwrite::Exception.new('Missing required parameter: "url"')
|
192
192
|
end
|
193
193
|
|
194
|
-
|
194
|
+
api_params = {
|
195
195
|
url: url,
|
196
196
|
width: width,
|
197
197
|
height: height,
|
198
198
|
}
|
199
199
|
|
200
|
-
|
200
|
+
api_headers = {
|
201
201
|
"content-type": 'application/json',
|
202
202
|
}
|
203
203
|
|
204
204
|
@client.call(
|
205
205
|
method: 'GET',
|
206
|
-
path:
|
207
|
-
headers:
|
208
|
-
params:
|
206
|
+
path: api_path,
|
207
|
+
headers: api_headers,
|
208
|
+
params: api_params,
|
209
209
|
)
|
210
210
|
end
|
211
211
|
|
@@ -234,24 +234,24 @@ module Appwrite
|
|
234
234
|
#
|
235
235
|
# @return []
|
236
236
|
def get_initials(name: nil, width: nil, height: nil, background: nil)
|
237
|
-
|
237
|
+
api_path = '/avatars/initials'
|
238
238
|
|
239
|
-
|
239
|
+
api_params = {
|
240
240
|
name: name,
|
241
241
|
width: width,
|
242
242
|
height: height,
|
243
243
|
background: background,
|
244
244
|
}
|
245
245
|
|
246
|
-
|
246
|
+
api_headers = {
|
247
247
|
"content-type": 'application/json',
|
248
248
|
}
|
249
249
|
|
250
250
|
@client.call(
|
251
251
|
method: 'GET',
|
252
|
-
path:
|
253
|
-
headers:
|
254
|
-
params:
|
252
|
+
path: api_path,
|
253
|
+
headers: api_headers,
|
254
|
+
params: api_params,
|
255
255
|
)
|
256
256
|
end
|
257
257
|
|
@@ -267,28 +267,28 @@ module Appwrite
|
|
267
267
|
#
|
268
268
|
# @return []
|
269
269
|
def get_qr(text:, size: nil, margin: nil, download: nil)
|
270
|
-
|
270
|
+
api_path = '/avatars/qr'
|
271
271
|
|
272
272
|
if text.nil?
|
273
273
|
raise Appwrite::Exception.new('Missing required parameter: "text"')
|
274
274
|
end
|
275
275
|
|
276
|
-
|
276
|
+
api_params = {
|
277
277
|
text: text,
|
278
278
|
size: size,
|
279
279
|
margin: margin,
|
280
280
|
download: download,
|
281
281
|
}
|
282
282
|
|
283
|
-
|
283
|
+
api_headers = {
|
284
284
|
"content-type": 'application/json',
|
285
285
|
}
|
286
286
|
|
287
287
|
@client.call(
|
288
288
|
method: 'GET',
|
289
|
-
path:
|
290
|
-
headers:
|
291
|
-
params:
|
289
|
+
path: api_path,
|
290
|
+
headers: api_headers,
|
291
|
+
params: api_params,
|
292
292
|
)
|
293
293
|
end
|
294
294
|
|