tangled
alpha
login
or
join now
dekker.one
/
pocketbase-reqwest
1
fork
atom
A wrapper around reqwest to make working with Pocketbase a breeze
1
fork
atom
overview
issues
pulls
pipelines
Add first version of the reqwest wrapper crate for pocketbase
dekker.one
10 months ago
8993706a
+2463
8 changed files
expand all
collapse all
unified
split
.gitignore
Cargo.lock
Cargo.toml
rustfmt.toml
src
auth.rs
health.rs
lib.rs
record.rs
+1
.gitignore
···
1
1
+
/target
+1614
Cargo.lock
···
1
1
+
# This file is automatically @generated by Cargo.
2
2
+
# It is not intended for manual editing.
3
3
+
version = 4
4
4
+
5
5
+
[[package]]
6
6
+
name = "addr2line"
7
7
+
version = "0.24.2"
8
8
+
source = "registry+https://github.com/rust-lang/crates.io-index"
9
9
+
checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1"
10
10
+
dependencies = [
11
11
+
"gimli",
12
12
+
]
13
13
+
14
14
+
[[package]]
15
15
+
name = "adler2"
16
16
+
version = "2.0.0"
17
17
+
source = "registry+https://github.com/rust-lang/crates.io-index"
18
18
+
checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627"
19
19
+
20
20
+
[[package]]
21
21
+
name = "atomic-waker"
22
22
+
version = "1.1.2"
23
23
+
source = "registry+https://github.com/rust-lang/crates.io-index"
24
24
+
checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0"
25
25
+
26
26
+
[[package]]
27
27
+
name = "autocfg"
28
28
+
version = "1.4.0"
29
29
+
source = "registry+https://github.com/rust-lang/crates.io-index"
30
30
+
checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26"
31
31
+
32
32
+
[[package]]
33
33
+
name = "backtrace"
34
34
+
version = "0.3.74"
35
35
+
source = "registry+https://github.com/rust-lang/crates.io-index"
36
36
+
checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a"
37
37
+
dependencies = [
38
38
+
"addr2line",
39
39
+
"cfg-if",
40
40
+
"libc",
41
41
+
"miniz_oxide",
42
42
+
"object",
43
43
+
"rustc-demangle",
44
44
+
"windows-targets 0.52.6",
45
45
+
]
46
46
+
47
47
+
[[package]]
48
48
+
name = "base64"
49
49
+
version = "0.22.1"
50
50
+
source = "registry+https://github.com/rust-lang/crates.io-index"
51
51
+
checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"
52
52
+
53
53
+
[[package]]
54
54
+
name = "bitflags"
55
55
+
version = "2.9.0"
56
56
+
source = "registry+https://github.com/rust-lang/crates.io-index"
57
57
+
checksum = "5c8214115b7bf84099f1309324e63141d4c5d7cc26862f97a0a857dbefe165bd"
58
58
+
59
59
+
[[package]]
60
60
+
name = "bumpalo"
61
61
+
version = "3.17.0"
62
62
+
source = "registry+https://github.com/rust-lang/crates.io-index"
63
63
+
checksum = "1628fb46dfa0b37568d12e5edd512553eccf6a22a78e8bde00bb4aed84d5bdbf"
64
64
+
65
65
+
[[package]]
66
66
+
name = "bytes"
67
67
+
version = "1.10.1"
68
68
+
source = "registry+https://github.com/rust-lang/crates.io-index"
69
69
+
checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a"
70
70
+
71
71
+
[[package]]
72
72
+
name = "cc"
73
73
+
version = "1.2.17"
74
74
+
source = "registry+https://github.com/rust-lang/crates.io-index"
75
75
+
checksum = "1fcb57c740ae1daf453ae85f16e37396f672b039e00d9d866e07ddb24e328e3a"
76
76
+
dependencies = [
77
77
+
"shlex",
78
78
+
]
79
79
+
80
80
+
[[package]]
81
81
+
name = "cfg-if"
82
82
+
version = "1.0.0"
83
83
+
source = "registry+https://github.com/rust-lang/crates.io-index"
84
84
+
checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
85
85
+
86
86
+
[[package]]
87
87
+
name = "core-foundation"
88
88
+
version = "0.9.4"
89
89
+
source = "registry+https://github.com/rust-lang/crates.io-index"
90
90
+
checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f"
91
91
+
dependencies = [
92
92
+
"core-foundation-sys",
93
93
+
"libc",
94
94
+
]
95
95
+
96
96
+
[[package]]
97
97
+
name = "core-foundation-sys"
98
98
+
version = "0.8.7"
99
99
+
source = "registry+https://github.com/rust-lang/crates.io-index"
100
100
+
checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"
101
101
+
102
102
+
[[package]]
103
103
+
name = "displaydoc"
104
104
+
version = "0.2.5"
105
105
+
source = "registry+https://github.com/rust-lang/crates.io-index"
106
106
+
checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0"
107
107
+
dependencies = [
108
108
+
"proc-macro2",
109
109
+
"quote",
110
110
+
"syn",
111
111
+
]
112
112
+
113
113
+
[[package]]
114
114
+
name = "encoding_rs"
115
115
+
version = "0.8.35"
116
116
+
source = "registry+https://github.com/rust-lang/crates.io-index"
117
117
+
checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3"
118
118
+
dependencies = [
119
119
+
"cfg-if",
120
120
+
]
121
121
+
122
122
+
[[package]]
123
123
+
name = "equivalent"
124
124
+
version = "1.0.2"
125
125
+
source = "registry+https://github.com/rust-lang/crates.io-index"
126
126
+
checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"
127
127
+
128
128
+
[[package]]
129
129
+
name = "errno"
130
130
+
version = "0.3.10"
131
131
+
source = "registry+https://github.com/rust-lang/crates.io-index"
132
132
+
checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d"
133
133
+
dependencies = [
134
134
+
"libc",
135
135
+
"windows-sys 0.59.0",
136
136
+
]
137
137
+
138
138
+
[[package]]
139
139
+
name = "fastrand"
140
140
+
version = "2.3.0"
141
141
+
source = "registry+https://github.com/rust-lang/crates.io-index"
142
142
+
checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be"
143
143
+
144
144
+
[[package]]
145
145
+
name = "fnv"
146
146
+
version = "1.0.7"
147
147
+
source = "registry+https://github.com/rust-lang/crates.io-index"
148
148
+
checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
149
149
+
150
150
+
[[package]]
151
151
+
name = "foreign-types"
152
152
+
version = "0.3.2"
153
153
+
source = "registry+https://github.com/rust-lang/crates.io-index"
154
154
+
checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1"
155
155
+
dependencies = [
156
156
+
"foreign-types-shared",
157
157
+
]
158
158
+
159
159
+
[[package]]
160
160
+
name = "foreign-types-shared"
161
161
+
version = "0.1.1"
162
162
+
source = "registry+https://github.com/rust-lang/crates.io-index"
163
163
+
checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b"
164
164
+
165
165
+
[[package]]
166
166
+
name = "form_urlencoded"
167
167
+
version = "1.2.1"
168
168
+
source = "registry+https://github.com/rust-lang/crates.io-index"
169
169
+
checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456"
170
170
+
dependencies = [
171
171
+
"percent-encoding",
172
172
+
]
173
173
+
174
174
+
[[package]]
175
175
+
name = "futures-channel"
176
176
+
version = "0.3.31"
177
177
+
source = "registry+https://github.com/rust-lang/crates.io-index"
178
178
+
checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10"
179
179
+
dependencies = [
180
180
+
"futures-core",
181
181
+
]
182
182
+
183
183
+
[[package]]
184
184
+
name = "futures-core"
185
185
+
version = "0.3.31"
186
186
+
source = "registry+https://github.com/rust-lang/crates.io-index"
187
187
+
checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e"
188
188
+
189
189
+
[[package]]
190
190
+
name = "futures-sink"
191
191
+
version = "0.3.31"
192
192
+
source = "registry+https://github.com/rust-lang/crates.io-index"
193
193
+
checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7"
194
194
+
195
195
+
[[package]]
196
196
+
name = "futures-task"
197
197
+
version = "0.3.31"
198
198
+
source = "registry+https://github.com/rust-lang/crates.io-index"
199
199
+
checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988"
200
200
+
201
201
+
[[package]]
202
202
+
name = "futures-util"
203
203
+
version = "0.3.31"
204
204
+
source = "registry+https://github.com/rust-lang/crates.io-index"
205
205
+
checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81"
206
206
+
dependencies = [
207
207
+
"futures-core",
208
208
+
"futures-task",
209
209
+
"pin-project-lite",
210
210
+
"pin-utils",
211
211
+
]
212
212
+
213
213
+
[[package]]
214
214
+
name = "getrandom"
215
215
+
version = "0.2.15"
216
216
+
source = "registry+https://github.com/rust-lang/crates.io-index"
217
217
+
checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7"
218
218
+
dependencies = [
219
219
+
"cfg-if",
220
220
+
"libc",
221
221
+
"wasi 0.11.0+wasi-snapshot-preview1",
222
222
+
]
223
223
+
224
224
+
[[package]]
225
225
+
name = "getrandom"
226
226
+
version = "0.3.2"
227
227
+
source = "registry+https://github.com/rust-lang/crates.io-index"
228
228
+
checksum = "73fea8450eea4bac3940448fb7ae50d91f034f941199fcd9d909a5a07aa455f0"
229
229
+
dependencies = [
230
230
+
"cfg-if",
231
231
+
"libc",
232
232
+
"r-efi",
233
233
+
"wasi 0.14.2+wasi-0.2.4",
234
234
+
]
235
235
+
236
236
+
[[package]]
237
237
+
name = "gimli"
238
238
+
version = "0.31.1"
239
239
+
source = "registry+https://github.com/rust-lang/crates.io-index"
240
240
+
checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f"
241
241
+
242
242
+
[[package]]
243
243
+
name = "h2"
244
244
+
version = "0.4.8"
245
245
+
source = "registry+https://github.com/rust-lang/crates.io-index"
246
246
+
checksum = "5017294ff4bb30944501348f6f8e42e6ad28f42c8bbef7a74029aff064a4e3c2"
247
247
+
dependencies = [
248
248
+
"atomic-waker",
249
249
+
"bytes",
250
250
+
"fnv",
251
251
+
"futures-core",
252
252
+
"futures-sink",
253
253
+
"http",
254
254
+
"indexmap",
255
255
+
"slab",
256
256
+
"tokio",
257
257
+
"tokio-util",
258
258
+
"tracing",
259
259
+
]
260
260
+
261
261
+
[[package]]
262
262
+
name = "hashbrown"
263
263
+
version = "0.15.2"
264
264
+
source = "registry+https://github.com/rust-lang/crates.io-index"
265
265
+
checksum = "bf151400ff0baff5465007dd2f3e717f3fe502074ca563069ce3a6629d07b289"
266
266
+
267
267
+
[[package]]
268
268
+
name = "http"
269
269
+
version = "1.3.1"
270
270
+
source = "registry+https://github.com/rust-lang/crates.io-index"
271
271
+
checksum = "f4a85d31aea989eead29a3aaf9e1115a180df8282431156e533de47660892565"
272
272
+
dependencies = [
273
273
+
"bytes",
274
274
+
"fnv",
275
275
+
"itoa",
276
276
+
]
277
277
+
278
278
+
[[package]]
279
279
+
name = "http-body"
280
280
+
version = "1.0.1"
281
281
+
source = "registry+https://github.com/rust-lang/crates.io-index"
282
282
+
checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184"
283
283
+
dependencies = [
284
284
+
"bytes",
285
285
+
"http",
286
286
+
]
287
287
+
288
288
+
[[package]]
289
289
+
name = "http-body-util"
290
290
+
version = "0.1.3"
291
291
+
source = "registry+https://github.com/rust-lang/crates.io-index"
292
292
+
checksum = "b021d93e26becf5dc7e1b75b1bed1fd93124b374ceb73f43d4d4eafec896a64a"
293
293
+
dependencies = [
294
294
+
"bytes",
295
295
+
"futures-core",
296
296
+
"http",
297
297
+
"http-body",
298
298
+
"pin-project-lite",
299
299
+
]
300
300
+
301
301
+
[[package]]
302
302
+
name = "httparse"
303
303
+
version = "1.10.1"
304
304
+
source = "registry+https://github.com/rust-lang/crates.io-index"
305
305
+
checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"
306
306
+
307
307
+
[[package]]
308
308
+
name = "hyper"
309
309
+
version = "1.6.0"
310
310
+
source = "registry+https://github.com/rust-lang/crates.io-index"
311
311
+
checksum = "cc2b571658e38e0c01b1fdca3bbbe93c00d3d71693ff2770043f8c29bc7d6f80"
312
312
+
dependencies = [
313
313
+
"bytes",
314
314
+
"futures-channel",
315
315
+
"futures-util",
316
316
+
"h2",
317
317
+
"http",
318
318
+
"http-body",
319
319
+
"httparse",
320
320
+
"itoa",
321
321
+
"pin-project-lite",
322
322
+
"smallvec",
323
323
+
"tokio",
324
324
+
"want",
325
325
+
]
326
326
+
327
327
+
[[package]]
328
328
+
name = "hyper-rustls"
329
329
+
version = "0.27.5"
330
330
+
source = "registry+https://github.com/rust-lang/crates.io-index"
331
331
+
checksum = "2d191583f3da1305256f22463b9bb0471acad48a4e534a5218b9963e9c1f59b2"
332
332
+
dependencies = [
333
333
+
"futures-util",
334
334
+
"http",
335
335
+
"hyper",
336
336
+
"hyper-util",
337
337
+
"rustls",
338
338
+
"rustls-pki-types",
339
339
+
"tokio",
340
340
+
"tokio-rustls",
341
341
+
"tower-service",
342
342
+
]
343
343
+
344
344
+
[[package]]
345
345
+
name = "hyper-tls"
346
346
+
version = "0.6.0"
347
347
+
source = "registry+https://github.com/rust-lang/crates.io-index"
348
348
+
checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0"
349
349
+
dependencies = [
350
350
+
"bytes",
351
351
+
"http-body-util",
352
352
+
"hyper",
353
353
+
"hyper-util",
354
354
+
"native-tls",
355
355
+
"tokio",
356
356
+
"tokio-native-tls",
357
357
+
"tower-service",
358
358
+
]
359
359
+
360
360
+
[[package]]
361
361
+
name = "hyper-util"
362
362
+
version = "0.1.10"
363
363
+
source = "registry+https://github.com/rust-lang/crates.io-index"
364
364
+
checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4"
365
365
+
dependencies = [
366
366
+
"bytes",
367
367
+
"futures-channel",
368
368
+
"futures-util",
369
369
+
"http",
370
370
+
"http-body",
371
371
+
"hyper",
372
372
+
"pin-project-lite",
373
373
+
"socket2",
374
374
+
"tokio",
375
375
+
"tower-service",
376
376
+
"tracing",
377
377
+
]
378
378
+
379
379
+
[[package]]
380
380
+
name = "icu_collections"
381
381
+
version = "1.5.0"
382
382
+
source = "registry+https://github.com/rust-lang/crates.io-index"
383
383
+
checksum = "db2fa452206ebee18c4b5c2274dbf1de17008e874b4dc4f0aea9d01ca79e4526"
384
384
+
dependencies = [
385
385
+
"displaydoc",
386
386
+
"yoke",
387
387
+
"zerofrom",
388
388
+
"zerovec",
389
389
+
]
390
390
+
391
391
+
[[package]]
392
392
+
name = "icu_locid"
393
393
+
version = "1.5.0"
394
394
+
source = "registry+https://github.com/rust-lang/crates.io-index"
395
395
+
checksum = "13acbb8371917fc971be86fc8057c41a64b521c184808a698c02acc242dbf637"
396
396
+
dependencies = [
397
397
+
"displaydoc",
398
398
+
"litemap",
399
399
+
"tinystr",
400
400
+
"writeable",
401
401
+
"zerovec",
402
402
+
]
403
403
+
404
404
+
[[package]]
405
405
+
name = "icu_locid_transform"
406
406
+
version = "1.5.0"
407
407
+
source = "registry+https://github.com/rust-lang/crates.io-index"
408
408
+
checksum = "01d11ac35de8e40fdeda00d9e1e9d92525f3f9d887cdd7aa81d727596788b54e"
409
409
+
dependencies = [
410
410
+
"displaydoc",
411
411
+
"icu_locid",
412
412
+
"icu_locid_transform_data",
413
413
+
"icu_provider",
414
414
+
"tinystr",
415
415
+
"zerovec",
416
416
+
]
417
417
+
418
418
+
[[package]]
419
419
+
name = "icu_locid_transform_data"
420
420
+
version = "1.5.0"
421
421
+
source = "registry+https://github.com/rust-lang/crates.io-index"
422
422
+
checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e"
423
423
+
424
424
+
[[package]]
425
425
+
name = "icu_normalizer"
426
426
+
version = "1.5.0"
427
427
+
source = "registry+https://github.com/rust-lang/crates.io-index"
428
428
+
checksum = "19ce3e0da2ec68599d193c93d088142efd7f9c5d6fc9b803774855747dc6a84f"
429
429
+
dependencies = [
430
430
+
"displaydoc",
431
431
+
"icu_collections",
432
432
+
"icu_normalizer_data",
433
433
+
"icu_properties",
434
434
+
"icu_provider",
435
435
+
"smallvec",
436
436
+
"utf16_iter",
437
437
+
"utf8_iter",
438
438
+
"write16",
439
439
+
"zerovec",
440
440
+
]
441
441
+
442
442
+
[[package]]
443
443
+
name = "icu_normalizer_data"
444
444
+
version = "1.5.0"
445
445
+
source = "registry+https://github.com/rust-lang/crates.io-index"
446
446
+
checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516"
447
447
+
448
448
+
[[package]]
449
449
+
name = "icu_properties"
450
450
+
version = "1.5.1"
451
451
+
source = "registry+https://github.com/rust-lang/crates.io-index"
452
452
+
checksum = "93d6020766cfc6302c15dbbc9c8778c37e62c14427cb7f6e601d849e092aeef5"
453
453
+
dependencies = [
454
454
+
"displaydoc",
455
455
+
"icu_collections",
456
456
+
"icu_locid_transform",
457
457
+
"icu_properties_data",
458
458
+
"icu_provider",
459
459
+
"tinystr",
460
460
+
"zerovec",
461
461
+
]
462
462
+
463
463
+
[[package]]
464
464
+
name = "icu_properties_data"
465
465
+
version = "1.5.0"
466
466
+
source = "registry+https://github.com/rust-lang/crates.io-index"
467
467
+
checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569"
468
468
+
469
469
+
[[package]]
470
470
+
name = "icu_provider"
471
471
+
version = "1.5.0"
472
472
+
source = "registry+https://github.com/rust-lang/crates.io-index"
473
473
+
checksum = "6ed421c8a8ef78d3e2dbc98a973be2f3770cb42b606e3ab18d6237c4dfde68d9"
474
474
+
dependencies = [
475
475
+
"displaydoc",
476
476
+
"icu_locid",
477
477
+
"icu_provider_macros",
478
478
+
"stable_deref_trait",
479
479
+
"tinystr",
480
480
+
"writeable",
481
481
+
"yoke",
482
482
+
"zerofrom",
483
483
+
"zerovec",
484
484
+
]
485
485
+
486
486
+
[[package]]
487
487
+
name = "icu_provider_macros"
488
488
+
version = "1.5.0"
489
489
+
source = "registry+https://github.com/rust-lang/crates.io-index"
490
490
+
checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6"
491
491
+
dependencies = [
492
492
+
"proc-macro2",
493
493
+
"quote",
494
494
+
"syn",
495
495
+
]
496
496
+
497
497
+
[[package]]
498
498
+
name = "idna"
499
499
+
version = "1.0.3"
500
500
+
source = "registry+https://github.com/rust-lang/crates.io-index"
501
501
+
checksum = "686f825264d630750a544639377bae737628043f20d38bbc029e8f29ea968a7e"
502
502
+
dependencies = [
503
503
+
"idna_adapter",
504
504
+
"smallvec",
505
505
+
"utf8_iter",
506
506
+
]
507
507
+
508
508
+
[[package]]
509
509
+
name = "idna_adapter"
510
510
+
version = "1.2.0"
511
511
+
source = "registry+https://github.com/rust-lang/crates.io-index"
512
512
+
checksum = "daca1df1c957320b2cf139ac61e7bd64fed304c5040df000a745aa1de3b4ef71"
513
513
+
dependencies = [
514
514
+
"icu_normalizer",
515
515
+
"icu_properties",
516
516
+
]
517
517
+
518
518
+
[[package]]
519
519
+
name = "indexmap"
520
520
+
version = "2.8.0"
521
521
+
source = "registry+https://github.com/rust-lang/crates.io-index"
522
522
+
checksum = "3954d50fe15b02142bf25d3b8bdadb634ec3948f103d04ffe3031bc8fe9d7058"
523
523
+
dependencies = [
524
524
+
"equivalent",
525
525
+
"hashbrown",
526
526
+
]
527
527
+
528
528
+
[[package]]
529
529
+
name = "ipnet"
530
530
+
version = "2.11.0"
531
531
+
source = "registry+https://github.com/rust-lang/crates.io-index"
532
532
+
checksum = "469fb0b9cefa57e3ef31275ee7cacb78f2fdca44e4765491884a2b119d4eb130"
533
533
+
534
534
+
[[package]]
535
535
+
name = "itoa"
536
536
+
version = "1.0.15"
537
537
+
source = "registry+https://github.com/rust-lang/crates.io-index"
538
538
+
checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c"
539
539
+
540
540
+
[[package]]
541
541
+
name = "js-sys"
542
542
+
version = "0.3.77"
543
543
+
source = "registry+https://github.com/rust-lang/crates.io-index"
544
544
+
checksum = "1cfaf33c695fc6e08064efbc1f72ec937429614f25eef83af942d0e227c3a28f"
545
545
+
dependencies = [
546
546
+
"once_cell",
547
547
+
"wasm-bindgen",
548
548
+
]
549
549
+
550
550
+
[[package]]
551
551
+
name = "libc"
552
552
+
version = "0.2.171"
553
553
+
source = "registry+https://github.com/rust-lang/crates.io-index"
554
554
+
checksum = "c19937216e9d3aa9956d9bb8dfc0b0c8beb6058fc4f7a4dc4d850edf86a237d6"
555
555
+
556
556
+
[[package]]
557
557
+
name = "linux-raw-sys"
558
558
+
version = "0.9.3"
559
559
+
source = "registry+https://github.com/rust-lang/crates.io-index"
560
560
+
checksum = "fe7db12097d22ec582439daf8618b8fdd1a7bef6270e9af3b1ebcd30893cf413"
561
561
+
562
562
+
[[package]]
563
563
+
name = "litemap"
564
564
+
version = "0.7.5"
565
565
+
source = "registry+https://github.com/rust-lang/crates.io-index"
566
566
+
checksum = "23fb14cb19457329c82206317a5663005a4d404783dc74f4252769b0d5f42856"
567
567
+
568
568
+
[[package]]
569
569
+
name = "log"
570
570
+
version = "0.4.26"
571
571
+
source = "registry+https://github.com/rust-lang/crates.io-index"
572
572
+
checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e"
573
573
+
574
574
+
[[package]]
575
575
+
name = "memchr"
576
576
+
version = "2.7.4"
577
577
+
source = "registry+https://github.com/rust-lang/crates.io-index"
578
578
+
checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"
579
579
+
580
580
+
[[package]]
581
581
+
name = "mime"
582
582
+
version = "0.3.17"
583
583
+
source = "registry+https://github.com/rust-lang/crates.io-index"
584
584
+
checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"
585
585
+
586
586
+
[[package]]
587
587
+
name = "miniz_oxide"
588
588
+
version = "0.8.5"
589
589
+
source = "registry+https://github.com/rust-lang/crates.io-index"
590
590
+
checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5"
591
591
+
dependencies = [
592
592
+
"adler2",
593
593
+
]
594
594
+
595
595
+
[[package]]
596
596
+
name = "mio"
597
597
+
version = "1.0.3"
598
598
+
source = "registry+https://github.com/rust-lang/crates.io-index"
599
599
+
checksum = "2886843bf800fba2e3377cff24abf6379b4c4d5c6681eaf9ea5b0d15090450bd"
600
600
+
dependencies = [
601
601
+
"libc",
602
602
+
"wasi 0.11.0+wasi-snapshot-preview1",
603
603
+
"windows-sys 0.52.0",
604
604
+
]
605
605
+
606
606
+
[[package]]
607
607
+
name = "native-tls"
608
608
+
version = "0.2.14"
609
609
+
source = "registry+https://github.com/rust-lang/crates.io-index"
610
610
+
checksum = "87de3442987e9dbec73158d5c715e7ad9072fda936bb03d19d7fa10e00520f0e"
611
611
+
dependencies = [
612
612
+
"libc",
613
613
+
"log",
614
614
+
"openssl",
615
615
+
"openssl-probe",
616
616
+
"openssl-sys",
617
617
+
"schannel",
618
618
+
"security-framework",
619
619
+
"security-framework-sys",
620
620
+
"tempfile",
621
621
+
]
622
622
+
623
623
+
[[package]]
624
624
+
name = "object"
625
625
+
version = "0.36.7"
626
626
+
source = "registry+https://github.com/rust-lang/crates.io-index"
627
627
+
checksum = "62948e14d923ea95ea2c7c86c71013138b66525b86bdc08d2dcc262bdb497b87"
628
628
+
dependencies = [
629
629
+
"memchr",
630
630
+
]
631
631
+
632
632
+
[[package]]
633
633
+
name = "once_cell"
634
634
+
version = "1.21.1"
635
635
+
source = "registry+https://github.com/rust-lang/crates.io-index"
636
636
+
checksum = "d75b0bedcc4fe52caa0e03d9f1151a323e4aa5e2d78ba3580400cd3c9e2bc4bc"
637
637
+
638
638
+
[[package]]
639
639
+
name = "openssl"
640
640
+
version = "0.10.71"
641
641
+
source = "registry+https://github.com/rust-lang/crates.io-index"
642
642
+
checksum = "5e14130c6a98cd258fdcb0fb6d744152343ff729cbfcb28c656a9d12b999fbcd"
643
643
+
dependencies = [
644
644
+
"bitflags",
645
645
+
"cfg-if",
646
646
+
"foreign-types",
647
647
+
"libc",
648
648
+
"once_cell",
649
649
+
"openssl-macros",
650
650
+
"openssl-sys",
651
651
+
]
652
652
+
653
653
+
[[package]]
654
654
+
name = "openssl-macros"
655
655
+
version = "0.1.1"
656
656
+
source = "registry+https://github.com/rust-lang/crates.io-index"
657
657
+
checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c"
658
658
+
dependencies = [
659
659
+
"proc-macro2",
660
660
+
"quote",
661
661
+
"syn",
662
662
+
]
663
663
+
664
664
+
[[package]]
665
665
+
name = "openssl-probe"
666
666
+
version = "0.1.6"
667
667
+
source = "registry+https://github.com/rust-lang/crates.io-index"
668
668
+
checksum = "d05e27ee213611ffe7d6348b942e8f942b37114c00cc03cec254295a4a17852e"
669
669
+
670
670
+
[[package]]
671
671
+
name = "openssl-sys"
672
672
+
version = "0.9.106"
673
673
+
source = "registry+https://github.com/rust-lang/crates.io-index"
674
674
+
checksum = "8bb61ea9811cc39e3c2069f40b8b8e2e70d8569b361f879786cc7ed48b777cdd"
675
675
+
dependencies = [
676
676
+
"cc",
677
677
+
"libc",
678
678
+
"pkg-config",
679
679
+
"vcpkg",
680
680
+
]
681
681
+
682
682
+
[[package]]
683
683
+
name = "percent-encoding"
684
684
+
version = "2.3.1"
685
685
+
source = "registry+https://github.com/rust-lang/crates.io-index"
686
686
+
checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e"
687
687
+
688
688
+
[[package]]
689
689
+
name = "pin-project-lite"
690
690
+
version = "0.2.16"
691
691
+
source = "registry+https://github.com/rust-lang/crates.io-index"
692
692
+
checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b"
693
693
+
694
694
+
[[package]]
695
695
+
name = "pin-utils"
696
696
+
version = "0.1.0"
697
697
+
source = "registry+https://github.com/rust-lang/crates.io-index"
698
698
+
checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184"
699
699
+
700
700
+
[[package]]
701
701
+
name = "pkg-config"
702
702
+
version = "0.3.32"
703
703
+
source = "registry+https://github.com/rust-lang/crates.io-index"
704
704
+
checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c"
705
705
+
706
706
+
[[package]]
707
707
+
name = "pocketbase-reqwest"
708
708
+
version = "0.1.0"
709
709
+
dependencies = [
710
710
+
"base64",
711
711
+
"reqwest",
712
712
+
"serde",
713
713
+
"serde_json",
714
714
+
"thiserror",
715
715
+
"url",
716
716
+
"web-time",
717
717
+
]
718
718
+
719
719
+
[[package]]
720
720
+
name = "proc-macro2"
721
721
+
version = "1.0.94"
722
722
+
source = "registry+https://github.com/rust-lang/crates.io-index"
723
723
+
checksum = "a31971752e70b8b2686d7e46ec17fb38dad4051d94024c88df49b667caea9c84"
724
724
+
dependencies = [
725
725
+
"unicode-ident",
726
726
+
]
727
727
+
728
728
+
[[package]]
729
729
+
name = "quote"
730
730
+
version = "1.0.40"
731
731
+
source = "registry+https://github.com/rust-lang/crates.io-index"
732
732
+
checksum = "1885c039570dc00dcb4ff087a89e185fd56bae234ddc7f056a945bf36467248d"
733
733
+
dependencies = [
734
734
+
"proc-macro2",
735
735
+
]
736
736
+
737
737
+
[[package]]
738
738
+
name = "r-efi"
739
739
+
version = "5.2.0"
740
740
+
source = "registry+https://github.com/rust-lang/crates.io-index"
741
741
+
checksum = "74765f6d916ee2faa39bc8e68e4f3ed8949b48cccdac59983d287a7cb71ce9c5"
742
742
+
743
743
+
[[package]]
744
744
+
name = "reqwest"
745
745
+
version = "0.12.15"
746
746
+
source = "registry+https://github.com/rust-lang/crates.io-index"
747
747
+
checksum = "d19c46a6fdd48bc4dab94b6103fccc55d34c67cc0ad04653aad4ea2a07cd7bbb"
748
748
+
dependencies = [
749
749
+
"base64",
750
750
+
"bytes",
751
751
+
"encoding_rs",
752
752
+
"futures-core",
753
753
+
"futures-util",
754
754
+
"h2",
755
755
+
"http",
756
756
+
"http-body",
757
757
+
"http-body-util",
758
758
+
"hyper",
759
759
+
"hyper-rustls",
760
760
+
"hyper-tls",
761
761
+
"hyper-util",
762
762
+
"ipnet",
763
763
+
"js-sys",
764
764
+
"log",
765
765
+
"mime",
766
766
+
"native-tls",
767
767
+
"once_cell",
768
768
+
"percent-encoding",
769
769
+
"pin-project-lite",
770
770
+
"rustls-pemfile",
771
771
+
"serde",
772
772
+
"serde_json",
773
773
+
"serde_urlencoded",
774
774
+
"sync_wrapper",
775
775
+
"system-configuration",
776
776
+
"tokio",
777
777
+
"tokio-native-tls",
778
778
+
"tower",
779
779
+
"tower-service",
780
780
+
"url",
781
781
+
"wasm-bindgen",
782
782
+
"wasm-bindgen-futures",
783
783
+
"web-sys",
784
784
+
"windows-registry",
785
785
+
]
786
786
+
787
787
+
[[package]]
788
788
+
name = "ring"
789
789
+
version = "0.17.14"
790
790
+
source = "registry+https://github.com/rust-lang/crates.io-index"
791
791
+
checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7"
792
792
+
dependencies = [
793
793
+
"cc",
794
794
+
"cfg-if",
795
795
+
"getrandom 0.2.15",
796
796
+
"libc",
797
797
+
"untrusted",
798
798
+
"windows-sys 0.52.0",
799
799
+
]
800
800
+
801
801
+
[[package]]
802
802
+
name = "rustc-demangle"
803
803
+
version = "0.1.24"
804
804
+
source = "registry+https://github.com/rust-lang/crates.io-index"
805
805
+
checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f"
806
806
+
807
807
+
[[package]]
808
808
+
name = "rustix"
809
809
+
version = "1.0.3"
810
810
+
source = "registry+https://github.com/rust-lang/crates.io-index"
811
811
+
checksum = "e56a18552996ac8d29ecc3b190b4fdbb2d91ca4ec396de7bbffaf43f3d637e96"
812
812
+
dependencies = [
813
813
+
"bitflags",
814
814
+
"errno",
815
815
+
"libc",
816
816
+
"linux-raw-sys",
817
817
+
"windows-sys 0.59.0",
818
818
+
]
819
819
+
820
820
+
[[package]]
821
821
+
name = "rustls"
822
822
+
version = "0.23.25"
823
823
+
source = "registry+https://github.com/rust-lang/crates.io-index"
824
824
+
checksum = "822ee9188ac4ec04a2f0531e55d035fb2de73f18b41a63c70c2712503b6fb13c"
825
825
+
dependencies = [
826
826
+
"once_cell",
827
827
+
"rustls-pki-types",
828
828
+
"rustls-webpki",
829
829
+
"subtle",
830
830
+
"zeroize",
831
831
+
]
832
832
+
833
833
+
[[package]]
834
834
+
name = "rustls-pemfile"
835
835
+
version = "2.2.0"
836
836
+
source = "registry+https://github.com/rust-lang/crates.io-index"
837
837
+
checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50"
838
838
+
dependencies = [
839
839
+
"rustls-pki-types",
840
840
+
]
841
841
+
842
842
+
[[package]]
843
843
+
name = "rustls-pki-types"
844
844
+
version = "1.11.0"
845
845
+
source = "registry+https://github.com/rust-lang/crates.io-index"
846
846
+
checksum = "917ce264624a4b4db1c364dcc35bfca9ded014d0a958cd47ad3e960e988ea51c"
847
847
+
848
848
+
[[package]]
849
849
+
name = "rustls-webpki"
850
850
+
version = "0.103.0"
851
851
+
source = "registry+https://github.com/rust-lang/crates.io-index"
852
852
+
checksum = "0aa4eeac2588ffff23e9d7a7e9b3f971c5fb5b7ebc9452745e0c232c64f83b2f"
853
853
+
dependencies = [
854
854
+
"ring",
855
855
+
"rustls-pki-types",
856
856
+
"untrusted",
857
857
+
]
858
858
+
859
859
+
[[package]]
860
860
+
name = "rustversion"
861
861
+
version = "1.0.20"
862
862
+
source = "registry+https://github.com/rust-lang/crates.io-index"
863
863
+
checksum = "eded382c5f5f786b989652c49544c4877d9f015cc22e145a5ea8ea66c2921cd2"
864
864
+
865
865
+
[[package]]
866
866
+
name = "ryu"
867
867
+
version = "1.0.20"
868
868
+
source = "registry+https://github.com/rust-lang/crates.io-index"
869
869
+
checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f"
870
870
+
871
871
+
[[package]]
872
872
+
name = "schannel"
873
873
+
version = "0.1.27"
874
874
+
source = "registry+https://github.com/rust-lang/crates.io-index"
875
875
+
checksum = "1f29ebaa345f945cec9fbbc532eb307f0fdad8161f281b6369539c8d84876b3d"
876
876
+
dependencies = [
877
877
+
"windows-sys 0.59.0",
878
878
+
]
879
879
+
880
880
+
[[package]]
881
881
+
name = "security-framework"
882
882
+
version = "2.11.1"
883
883
+
source = "registry+https://github.com/rust-lang/crates.io-index"
884
884
+
checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02"
885
885
+
dependencies = [
886
886
+
"bitflags",
887
887
+
"core-foundation",
888
888
+
"core-foundation-sys",
889
889
+
"libc",
890
890
+
"security-framework-sys",
891
891
+
]
892
892
+
893
893
+
[[package]]
894
894
+
name = "security-framework-sys"
895
895
+
version = "2.14.0"
896
896
+
source = "registry+https://github.com/rust-lang/crates.io-index"
897
897
+
checksum = "49db231d56a190491cb4aeda9527f1ad45345af50b0851622a7adb8c03b01c32"
898
898
+
dependencies = [
899
899
+
"core-foundation-sys",
900
900
+
"libc",
901
901
+
]
902
902
+
903
903
+
[[package]]
904
904
+
name = "serde"
905
905
+
version = "1.0.219"
906
906
+
source = "registry+https://github.com/rust-lang/crates.io-index"
907
907
+
checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6"
908
908
+
dependencies = [
909
909
+
"serde_derive",
910
910
+
]
911
911
+
912
912
+
[[package]]
913
913
+
name = "serde_derive"
914
914
+
version = "1.0.219"
915
915
+
source = "registry+https://github.com/rust-lang/crates.io-index"
916
916
+
checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00"
917
917
+
dependencies = [
918
918
+
"proc-macro2",
919
919
+
"quote",
920
920
+
"syn",
921
921
+
]
922
922
+
923
923
+
[[package]]
924
924
+
name = "serde_json"
925
925
+
version = "1.0.140"
926
926
+
source = "registry+https://github.com/rust-lang/crates.io-index"
927
927
+
checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
928
928
+
dependencies = [
929
929
+
"itoa",
930
930
+
"memchr",
931
931
+
"ryu",
932
932
+
"serde",
933
933
+
]
934
934
+
935
935
+
[[package]]
936
936
+
name = "serde_urlencoded"
937
937
+
version = "0.7.1"
938
938
+
source = "registry+https://github.com/rust-lang/crates.io-index"
939
939
+
checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd"
940
940
+
dependencies = [
941
941
+
"form_urlencoded",
942
942
+
"itoa",
943
943
+
"ryu",
944
944
+
"serde",
945
945
+
]
946
946
+
947
947
+
[[package]]
948
948
+
name = "shlex"
949
949
+
version = "1.3.0"
950
950
+
source = "registry+https://github.com/rust-lang/crates.io-index"
951
951
+
checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"
952
952
+
953
953
+
[[package]]
954
954
+
name = "slab"
955
955
+
version = "0.4.9"
956
956
+
source = "registry+https://github.com/rust-lang/crates.io-index"
957
957
+
checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67"
958
958
+
dependencies = [
959
959
+
"autocfg",
960
960
+
]
961
961
+
962
962
+
[[package]]
963
963
+
name = "smallvec"
964
964
+
version = "1.14.0"
965
965
+
source = "registry+https://github.com/rust-lang/crates.io-index"
966
966
+
checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd"
967
967
+
968
968
+
[[package]]
969
969
+
name = "socket2"
970
970
+
version = "0.5.8"
971
971
+
source = "registry+https://github.com/rust-lang/crates.io-index"
972
972
+
checksum = "c970269d99b64e60ec3bd6ad27270092a5394c4e309314b18ae3fe575695fbe8"
973
973
+
dependencies = [
974
974
+
"libc",
975
975
+
"windows-sys 0.52.0",
976
976
+
]
977
977
+
978
978
+
[[package]]
979
979
+
name = "stable_deref_trait"
980
980
+
version = "1.2.0"
981
981
+
source = "registry+https://github.com/rust-lang/crates.io-index"
982
982
+
checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3"
983
983
+
984
984
+
[[package]]
985
985
+
name = "subtle"
986
986
+
version = "2.6.1"
987
987
+
source = "registry+https://github.com/rust-lang/crates.io-index"
988
988
+
checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"
989
989
+
990
990
+
[[package]]
991
991
+
name = "syn"
992
992
+
version = "2.0.100"
993
993
+
source = "registry+https://github.com/rust-lang/crates.io-index"
994
994
+
checksum = "b09a44accad81e1ba1cd74a32461ba89dee89095ba17b32f5d03683b1b1fc2a0"
995
995
+
dependencies = [
996
996
+
"proc-macro2",
997
997
+
"quote",
998
998
+
"unicode-ident",
999
999
+
]
1000
1000
+
1001
1001
+
[[package]]
1002
1002
+
name = "sync_wrapper"
1003
1003
+
version = "1.0.2"
1004
1004
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1005
1005
+
checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263"
1006
1006
+
dependencies = [
1007
1007
+
"futures-core",
1008
1008
+
]
1009
1009
+
1010
1010
+
[[package]]
1011
1011
+
name = "synstructure"
1012
1012
+
version = "0.13.1"
1013
1013
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1014
1014
+
checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971"
1015
1015
+
dependencies = [
1016
1016
+
"proc-macro2",
1017
1017
+
"quote",
1018
1018
+
"syn",
1019
1019
+
]
1020
1020
+
1021
1021
+
[[package]]
1022
1022
+
name = "system-configuration"
1023
1023
+
version = "0.6.1"
1024
1024
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1025
1025
+
checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b"
1026
1026
+
dependencies = [
1027
1027
+
"bitflags",
1028
1028
+
"core-foundation",
1029
1029
+
"system-configuration-sys",
1030
1030
+
]
1031
1031
+
1032
1032
+
[[package]]
1033
1033
+
name = "system-configuration-sys"
1034
1034
+
version = "0.6.0"
1035
1035
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1036
1036
+
checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4"
1037
1037
+
dependencies = [
1038
1038
+
"core-foundation-sys",
1039
1039
+
"libc",
1040
1040
+
]
1041
1041
+
1042
1042
+
[[package]]
1043
1043
+
name = "tempfile"
1044
1044
+
version = "3.19.1"
1045
1045
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1046
1046
+
checksum = "7437ac7763b9b123ccf33c338a5cc1bac6f69b45a136c19bdd8a65e3916435bf"
1047
1047
+
dependencies = [
1048
1048
+
"fastrand",
1049
1049
+
"getrandom 0.3.2",
1050
1050
+
"once_cell",
1051
1051
+
"rustix",
1052
1052
+
"windows-sys 0.59.0",
1053
1053
+
]
1054
1054
+
1055
1055
+
[[package]]
1056
1056
+
name = "thiserror"
1057
1057
+
version = "2.0.12"
1058
1058
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1059
1059
+
checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708"
1060
1060
+
dependencies = [
1061
1061
+
"thiserror-impl",
1062
1062
+
]
1063
1063
+
1064
1064
+
[[package]]
1065
1065
+
name = "thiserror-impl"
1066
1066
+
version = "2.0.12"
1067
1067
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1068
1068
+
checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d"
1069
1069
+
dependencies = [
1070
1070
+
"proc-macro2",
1071
1071
+
"quote",
1072
1072
+
"syn",
1073
1073
+
]
1074
1074
+
1075
1075
+
[[package]]
1076
1076
+
name = "tinystr"
1077
1077
+
version = "0.7.6"
1078
1078
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1079
1079
+
checksum = "9117f5d4db391c1cf6927e7bea3db74b9a1c1add8f7eda9ffd5364f40f57b82f"
1080
1080
+
dependencies = [
1081
1081
+
"displaydoc",
1082
1082
+
"zerovec",
1083
1083
+
]
1084
1084
+
1085
1085
+
[[package]]
1086
1086
+
name = "tokio"
1087
1087
+
version = "1.44.1"
1088
1088
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1089
1089
+
checksum = "f382da615b842244d4b8738c82ed1275e6c5dd90c459a30941cd07080b06c91a"
1090
1090
+
dependencies = [
1091
1091
+
"backtrace",
1092
1092
+
"bytes",
1093
1093
+
"libc",
1094
1094
+
"mio",
1095
1095
+
"pin-project-lite",
1096
1096
+
"socket2",
1097
1097
+
"windows-sys 0.52.0",
1098
1098
+
]
1099
1099
+
1100
1100
+
[[package]]
1101
1101
+
name = "tokio-native-tls"
1102
1102
+
version = "0.3.1"
1103
1103
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1104
1104
+
checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2"
1105
1105
+
dependencies = [
1106
1106
+
"native-tls",
1107
1107
+
"tokio",
1108
1108
+
]
1109
1109
+
1110
1110
+
[[package]]
1111
1111
+
name = "tokio-rustls"
1112
1112
+
version = "0.26.2"
1113
1113
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1114
1114
+
checksum = "8e727b36a1a0e8b74c376ac2211e40c2c8af09fb4013c60d910495810f008e9b"
1115
1115
+
dependencies = [
1116
1116
+
"rustls",
1117
1117
+
"tokio",
1118
1118
+
]
1119
1119
+
1120
1120
+
[[package]]
1121
1121
+
name = "tokio-util"
1122
1122
+
version = "0.7.14"
1123
1123
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1124
1124
+
checksum = "6b9590b93e6fcc1739458317cccd391ad3955e2bde8913edf6f95f9e65a8f034"
1125
1125
+
dependencies = [
1126
1126
+
"bytes",
1127
1127
+
"futures-core",
1128
1128
+
"futures-sink",
1129
1129
+
"pin-project-lite",
1130
1130
+
"tokio",
1131
1131
+
]
1132
1132
+
1133
1133
+
[[package]]
1134
1134
+
name = "tower"
1135
1135
+
version = "0.5.2"
1136
1136
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1137
1137
+
checksum = "d039ad9159c98b70ecfd540b2573b97f7f52c3e8d9f8ad57a24b916a536975f9"
1138
1138
+
dependencies = [
1139
1139
+
"futures-core",
1140
1140
+
"futures-util",
1141
1141
+
"pin-project-lite",
1142
1142
+
"sync_wrapper",
1143
1143
+
"tokio",
1144
1144
+
"tower-layer",
1145
1145
+
"tower-service",
1146
1146
+
]
1147
1147
+
1148
1148
+
[[package]]
1149
1149
+
name = "tower-layer"
1150
1150
+
version = "0.3.3"
1151
1151
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1152
1152
+
checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e"
1153
1153
+
1154
1154
+
[[package]]
1155
1155
+
name = "tower-service"
1156
1156
+
version = "0.3.3"
1157
1157
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1158
1158
+
checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3"
1159
1159
+
1160
1160
+
[[package]]
1161
1161
+
name = "tracing"
1162
1162
+
version = "0.1.41"
1163
1163
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1164
1164
+
checksum = "784e0ac535deb450455cbfa28a6f0df145ea1bb7ae51b821cf5e7927fdcfbdd0"
1165
1165
+
dependencies = [
1166
1166
+
"pin-project-lite",
1167
1167
+
"tracing-core",
1168
1168
+
]
1169
1169
+
1170
1170
+
[[package]]
1171
1171
+
name = "tracing-core"
1172
1172
+
version = "0.1.33"
1173
1173
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1174
1174
+
checksum = "e672c95779cf947c5311f83787af4fa8fffd12fb27e4993211a84bdfd9610f9c"
1175
1175
+
dependencies = [
1176
1176
+
"once_cell",
1177
1177
+
]
1178
1178
+
1179
1179
+
[[package]]
1180
1180
+
name = "try-lock"
1181
1181
+
version = "0.2.5"
1182
1182
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1183
1183
+
checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b"
1184
1184
+
1185
1185
+
[[package]]
1186
1186
+
name = "unicode-ident"
1187
1187
+
version = "1.0.18"
1188
1188
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1189
1189
+
checksum = "5a5f39404a5da50712a4c1eecf25e90dd62b613502b7e925fd4e4d19b5c96512"
1190
1190
+
1191
1191
+
[[package]]
1192
1192
+
name = "untrusted"
1193
1193
+
version = "0.9.0"
1194
1194
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1195
1195
+
checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"
1196
1196
+
1197
1197
+
[[package]]
1198
1198
+
name = "url"
1199
1199
+
version = "2.5.4"
1200
1200
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1201
1201
+
checksum = "32f8b686cadd1473f4bd0117a5d28d36b1ade384ea9b5069a1c40aefed7fda60"
1202
1202
+
dependencies = [
1203
1203
+
"form_urlencoded",
1204
1204
+
"idna",
1205
1205
+
"percent-encoding",
1206
1206
+
]
1207
1207
+
1208
1208
+
[[package]]
1209
1209
+
name = "utf16_iter"
1210
1210
+
version = "1.0.5"
1211
1211
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1212
1212
+
checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246"
1213
1213
+
1214
1214
+
[[package]]
1215
1215
+
name = "utf8_iter"
1216
1216
+
version = "1.0.4"
1217
1217
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1218
1218
+
checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"
1219
1219
+
1220
1220
+
[[package]]
1221
1221
+
name = "vcpkg"
1222
1222
+
version = "0.2.15"
1223
1223
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1224
1224
+
checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"
1225
1225
+
1226
1226
+
[[package]]
1227
1227
+
name = "want"
1228
1228
+
version = "0.3.1"
1229
1229
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1230
1230
+
checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e"
1231
1231
+
dependencies = [
1232
1232
+
"try-lock",
1233
1233
+
]
1234
1234
+
1235
1235
+
[[package]]
1236
1236
+
name = "wasi"
1237
1237
+
version = "0.11.0+wasi-snapshot-preview1"
1238
1238
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1239
1239
+
checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423"
1240
1240
+
1241
1241
+
[[package]]
1242
1242
+
name = "wasi"
1243
1243
+
version = "0.14.2+wasi-0.2.4"
1244
1244
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1245
1245
+
checksum = "9683f9a5a998d873c0d21fcbe3c083009670149a8fab228644b8bd36b2c48cb3"
1246
1246
+
dependencies = [
1247
1247
+
"wit-bindgen-rt",
1248
1248
+
]
1249
1249
+
1250
1250
+
[[package]]
1251
1251
+
name = "wasm-bindgen"
1252
1252
+
version = "0.2.100"
1253
1253
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1254
1254
+
checksum = "1edc8929d7499fc4e8f0be2262a241556cfc54a0bea223790e71446f2aab1ef5"
1255
1255
+
dependencies = [
1256
1256
+
"cfg-if",
1257
1257
+
"once_cell",
1258
1258
+
"rustversion",
1259
1259
+
"wasm-bindgen-macro",
1260
1260
+
]
1261
1261
+
1262
1262
+
[[package]]
1263
1263
+
name = "wasm-bindgen-backend"
1264
1264
+
version = "0.2.100"
1265
1265
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1266
1266
+
checksum = "2f0a0651a5c2bc21487bde11ee802ccaf4c51935d0d3d42a6101f98161700bc6"
1267
1267
+
dependencies = [
1268
1268
+
"bumpalo",
1269
1269
+
"log",
1270
1270
+
"proc-macro2",
1271
1271
+
"quote",
1272
1272
+
"syn",
1273
1273
+
"wasm-bindgen-shared",
1274
1274
+
]
1275
1275
+
1276
1276
+
[[package]]
1277
1277
+
name = "wasm-bindgen-futures"
1278
1278
+
version = "0.4.50"
1279
1279
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1280
1280
+
checksum = "555d470ec0bc3bb57890405e5d4322cc9ea83cebb085523ced7be4144dac1e61"
1281
1281
+
dependencies = [
1282
1282
+
"cfg-if",
1283
1283
+
"js-sys",
1284
1284
+
"once_cell",
1285
1285
+
"wasm-bindgen",
1286
1286
+
"web-sys",
1287
1287
+
]
1288
1288
+
1289
1289
+
[[package]]
1290
1290
+
name = "wasm-bindgen-macro"
1291
1291
+
version = "0.2.100"
1292
1292
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1293
1293
+
checksum = "7fe63fc6d09ed3792bd0897b314f53de8e16568c2b3f7982f468c0bf9bd0b407"
1294
1294
+
dependencies = [
1295
1295
+
"quote",
1296
1296
+
"wasm-bindgen-macro-support",
1297
1297
+
]
1298
1298
+
1299
1299
+
[[package]]
1300
1300
+
name = "wasm-bindgen-macro-support"
1301
1301
+
version = "0.2.100"
1302
1302
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1303
1303
+
checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de"
1304
1304
+
dependencies = [
1305
1305
+
"proc-macro2",
1306
1306
+
"quote",
1307
1307
+
"syn",
1308
1308
+
"wasm-bindgen-backend",
1309
1309
+
"wasm-bindgen-shared",
1310
1310
+
]
1311
1311
+
1312
1312
+
[[package]]
1313
1313
+
name = "wasm-bindgen-shared"
1314
1314
+
version = "0.2.100"
1315
1315
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1316
1316
+
checksum = "1a05d73b933a847d6cccdda8f838a22ff101ad9bf93e33684f39c1f5f0eece3d"
1317
1317
+
dependencies = [
1318
1318
+
"unicode-ident",
1319
1319
+
]
1320
1320
+
1321
1321
+
[[package]]
1322
1322
+
name = "web-sys"
1323
1323
+
version = "0.3.77"
1324
1324
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1325
1325
+
checksum = "33b6dd2ef9186f1f2072e409e99cd22a975331a6b3591b12c764e0e55c60d5d2"
1326
1326
+
dependencies = [
1327
1327
+
"js-sys",
1328
1328
+
"wasm-bindgen",
1329
1329
+
]
1330
1330
+
1331
1331
+
[[package]]
1332
1332
+
name = "web-time"
1333
1333
+
version = "1.1.0"
1334
1334
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1335
1335
+
checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb"
1336
1336
+
dependencies = [
1337
1337
+
"js-sys",
1338
1338
+
"wasm-bindgen",
1339
1339
+
]
1340
1340
+
1341
1341
+
[[package]]
1342
1342
+
name = "windows-link"
1343
1343
+
version = "0.1.1"
1344
1344
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1345
1345
+
checksum = "76840935b766e1b0a05c0066835fb9ec80071d4c09a16f6bd5f7e655e3c14c38"
1346
1346
+
1347
1347
+
[[package]]
1348
1348
+
name = "windows-registry"
1349
1349
+
version = "0.4.0"
1350
1350
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1351
1351
+
checksum = "4286ad90ddb45071efd1a66dfa43eb02dd0dfbae1545ad6cc3c51cf34d7e8ba3"
1352
1352
+
dependencies = [
1353
1353
+
"windows-result",
1354
1354
+
"windows-strings",
1355
1355
+
"windows-targets 0.53.0",
1356
1356
+
]
1357
1357
+
1358
1358
+
[[package]]
1359
1359
+
name = "windows-result"
1360
1360
+
version = "0.3.2"
1361
1361
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1362
1362
+
checksum = "c64fd11a4fd95df68efcfee5f44a294fe71b8bc6a91993e2791938abcc712252"
1363
1363
+
dependencies = [
1364
1364
+
"windows-link",
1365
1365
+
]
1366
1366
+
1367
1367
+
[[package]]
1368
1368
+
name = "windows-strings"
1369
1369
+
version = "0.3.1"
1370
1370
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1371
1371
+
checksum = "87fa48cc5d406560701792be122a10132491cff9d0aeb23583cc2dcafc847319"
1372
1372
+
dependencies = [
1373
1373
+
"windows-link",
1374
1374
+
]
1375
1375
+
1376
1376
+
[[package]]
1377
1377
+
name = "windows-sys"
1378
1378
+
version = "0.52.0"
1379
1379
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1380
1380
+
checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d"
1381
1381
+
dependencies = [
1382
1382
+
"windows-targets 0.52.6",
1383
1383
+
]
1384
1384
+
1385
1385
+
[[package]]
1386
1386
+
name = "windows-sys"
1387
1387
+
version = "0.59.0"
1388
1388
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1389
1389
+
checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"
1390
1390
+
dependencies = [
1391
1391
+
"windows-targets 0.52.6",
1392
1392
+
]
1393
1393
+
1394
1394
+
[[package]]
1395
1395
+
name = "windows-targets"
1396
1396
+
version = "0.52.6"
1397
1397
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1398
1398
+
checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973"
1399
1399
+
dependencies = [
1400
1400
+
"windows_aarch64_gnullvm 0.52.6",
1401
1401
+
"windows_aarch64_msvc 0.52.6",
1402
1402
+
"windows_i686_gnu 0.52.6",
1403
1403
+
"windows_i686_gnullvm 0.52.6",
1404
1404
+
"windows_i686_msvc 0.52.6",
1405
1405
+
"windows_x86_64_gnu 0.52.6",
1406
1406
+
"windows_x86_64_gnullvm 0.52.6",
1407
1407
+
"windows_x86_64_msvc 0.52.6",
1408
1408
+
]
1409
1409
+
1410
1410
+
[[package]]
1411
1411
+
name = "windows-targets"
1412
1412
+
version = "0.53.0"
1413
1413
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1414
1414
+
checksum = "b1e4c7e8ceaaf9cb7d7507c974735728ab453b67ef8f18febdd7c11fe59dca8b"
1415
1415
+
dependencies = [
1416
1416
+
"windows_aarch64_gnullvm 0.53.0",
1417
1417
+
"windows_aarch64_msvc 0.53.0",
1418
1418
+
"windows_i686_gnu 0.53.0",
1419
1419
+
"windows_i686_gnullvm 0.53.0",
1420
1420
+
"windows_i686_msvc 0.53.0",
1421
1421
+
"windows_x86_64_gnu 0.53.0",
1422
1422
+
"windows_x86_64_gnullvm 0.53.0",
1423
1423
+
"windows_x86_64_msvc 0.53.0",
1424
1424
+
]
1425
1425
+
1426
1426
+
[[package]]
1427
1427
+
name = "windows_aarch64_gnullvm"
1428
1428
+
version = "0.52.6"
1429
1429
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1430
1430
+
checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3"
1431
1431
+
1432
1432
+
[[package]]
1433
1433
+
name = "windows_aarch64_gnullvm"
1434
1434
+
version = "0.53.0"
1435
1435
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1436
1436
+
checksum = "86b8d5f90ddd19cb4a147a5fa63ca848db3df085e25fee3cc10b39b6eebae764"
1437
1437
+
1438
1438
+
[[package]]
1439
1439
+
name = "windows_aarch64_msvc"
1440
1440
+
version = "0.52.6"
1441
1441
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1442
1442
+
checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469"
1443
1443
+
1444
1444
+
[[package]]
1445
1445
+
name = "windows_aarch64_msvc"
1446
1446
+
version = "0.53.0"
1447
1447
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1448
1448
+
checksum = "c7651a1f62a11b8cbd5e0d42526e55f2c99886c77e007179efff86c2b137e66c"
1449
1449
+
1450
1450
+
[[package]]
1451
1451
+
name = "windows_i686_gnu"
1452
1452
+
version = "0.52.6"
1453
1453
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1454
1454
+
checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b"
1455
1455
+
1456
1456
+
[[package]]
1457
1457
+
name = "windows_i686_gnu"
1458
1458
+
version = "0.53.0"
1459
1459
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1460
1460
+
checksum = "c1dc67659d35f387f5f6c479dc4e28f1d4bb90ddd1a5d3da2e5d97b42d6272c3"
1461
1461
+
1462
1462
+
[[package]]
1463
1463
+
name = "windows_i686_gnullvm"
1464
1464
+
version = "0.52.6"
1465
1465
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1466
1466
+
checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66"
1467
1467
+
1468
1468
+
[[package]]
1469
1469
+
name = "windows_i686_gnullvm"
1470
1470
+
version = "0.53.0"
1471
1471
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1472
1472
+
checksum = "9ce6ccbdedbf6d6354471319e781c0dfef054c81fbc7cf83f338a4296c0cae11"
1473
1473
+
1474
1474
+
[[package]]
1475
1475
+
name = "windows_i686_msvc"
1476
1476
+
version = "0.52.6"
1477
1477
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1478
1478
+
checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66"
1479
1479
+
1480
1480
+
[[package]]
1481
1481
+
name = "windows_i686_msvc"
1482
1482
+
version = "0.53.0"
1483
1483
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1484
1484
+
checksum = "581fee95406bb13382d2f65cd4a908ca7b1e4c2f1917f143ba16efe98a589b5d"
1485
1485
+
1486
1486
+
[[package]]
1487
1487
+
name = "windows_x86_64_gnu"
1488
1488
+
version = "0.52.6"
1489
1489
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1490
1490
+
checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78"
1491
1491
+
1492
1492
+
[[package]]
1493
1493
+
name = "windows_x86_64_gnu"
1494
1494
+
version = "0.53.0"
1495
1495
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1496
1496
+
checksum = "2e55b5ac9ea33f2fc1716d1742db15574fd6fc8dadc51caab1c16a3d3b4190ba"
1497
1497
+
1498
1498
+
[[package]]
1499
1499
+
name = "windows_x86_64_gnullvm"
1500
1500
+
version = "0.52.6"
1501
1501
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1502
1502
+
checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d"
1503
1503
+
1504
1504
+
[[package]]
1505
1505
+
name = "windows_x86_64_gnullvm"
1506
1506
+
version = "0.53.0"
1507
1507
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1508
1508
+
checksum = "0a6e035dd0599267ce1ee132e51c27dd29437f63325753051e71dd9e42406c57"
1509
1509
+
1510
1510
+
[[package]]
1511
1511
+
name = "windows_x86_64_msvc"
1512
1512
+
version = "0.52.6"
1513
1513
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1514
1514
+
checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
1515
1515
+
1516
1516
+
[[package]]
1517
1517
+
name = "windows_x86_64_msvc"
1518
1518
+
version = "0.53.0"
1519
1519
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1520
1520
+
checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486"
1521
1521
+
1522
1522
+
[[package]]
1523
1523
+
name = "wit-bindgen-rt"
1524
1524
+
version = "0.39.0"
1525
1525
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1526
1526
+
checksum = "6f42320e61fe2cfd34354ecb597f86f413484a798ba44a8ca1165c58d42da6c1"
1527
1527
+
dependencies = [
1528
1528
+
"bitflags",
1529
1529
+
]
1530
1530
+
1531
1531
+
[[package]]
1532
1532
+
name = "write16"
1533
1533
+
version = "1.0.0"
1534
1534
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1535
1535
+
checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936"
1536
1536
+
1537
1537
+
[[package]]
1538
1538
+
name = "writeable"
1539
1539
+
version = "0.5.5"
1540
1540
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1541
1541
+
checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51"
1542
1542
+
1543
1543
+
[[package]]
1544
1544
+
name = "yoke"
1545
1545
+
version = "0.7.5"
1546
1546
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1547
1547
+
checksum = "120e6aef9aa629e3d4f52dc8cc43a015c7724194c97dfaf45180d2daf2b77f40"
1548
1548
+
dependencies = [
1549
1549
+
"serde",
1550
1550
+
"stable_deref_trait",
1551
1551
+
"yoke-derive",
1552
1552
+
"zerofrom",
1553
1553
+
]
1554
1554
+
1555
1555
+
[[package]]
1556
1556
+
name = "yoke-derive"
1557
1557
+
version = "0.7.5"
1558
1558
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1559
1559
+
checksum = "2380878cad4ac9aac1e2435f3eb4020e8374b5f13c296cb75b4620ff8e229154"
1560
1560
+
dependencies = [
1561
1561
+
"proc-macro2",
1562
1562
+
"quote",
1563
1563
+
"syn",
1564
1564
+
"synstructure",
1565
1565
+
]
1566
1566
+
1567
1567
+
[[package]]
1568
1568
+
name = "zerofrom"
1569
1569
+
version = "0.1.6"
1570
1570
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1571
1571
+
checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5"
1572
1572
+
dependencies = [
1573
1573
+
"zerofrom-derive",
1574
1574
+
]
1575
1575
+
1576
1576
+
[[package]]
1577
1577
+
name = "zerofrom-derive"
1578
1578
+
version = "0.1.6"
1579
1579
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1580
1580
+
checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502"
1581
1581
+
dependencies = [
1582
1582
+
"proc-macro2",
1583
1583
+
"quote",
1584
1584
+
"syn",
1585
1585
+
"synstructure",
1586
1586
+
]
1587
1587
+
1588
1588
+
[[package]]
1589
1589
+
name = "zeroize"
1590
1590
+
version = "1.8.1"
1591
1591
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1592
1592
+
checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde"
1593
1593
+
1594
1594
+
[[package]]
1595
1595
+
name = "zerovec"
1596
1596
+
version = "0.10.4"
1597
1597
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1598
1598
+
checksum = "aa2b893d79df23bfb12d5461018d408ea19dfafe76c2c7ef6d4eba614f8ff079"
1599
1599
+
dependencies = [
1600
1600
+
"yoke",
1601
1601
+
"zerofrom",
1602
1602
+
"zerovec-derive",
1603
1603
+
]
1604
1604
+
1605
1605
+
[[package]]
1606
1606
+
name = "zerovec-derive"
1607
1607
+
version = "0.10.3"
1608
1608
+
source = "registry+https://github.com/rust-lang/crates.io-index"
1609
1609
+
checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6"
1610
1610
+
dependencies = [
1611
1611
+
"proc-macro2",
1612
1612
+
"quote",
1613
1613
+
"syn",
1614
1614
+
]
+15
Cargo.toml
···
1
1
+
[package]
2
2
+
name = "pocketbase-reqwest"
3
3
+
version = "0.1.0"
4
4
+
edition = "2024"
5
5
+
6
6
+
[dependencies]
7
7
+
base64 = "0.22.1"
8
8
+
reqwest = { version = "0.12.15", features = ["json"] }
9
9
+
serde = { version = "1.0.219", features = ["derive"] }
10
10
+
serde_json = "1.0.140"
11
11
+
thiserror = "2.0.12"
12
12
+
url = "2.5.4"
13
13
+
14
14
+
[target.'cfg(target_arch = "wasm32")'.dependencies]
15
15
+
web-time = "1.1.0"
+3
rustfmt.toml
···
1
1
+
hard_tabs = true
2
2
+
imports_granularity = "Crate"
3
3
+
group_imports = "StdExternalCrate"
+191
src/auth.rs
···
1
1
+
use base64::{Engine, prelude::BASE64_STANDARD_NO_PAD};
2
2
+
use reqwest::{Method, header::HeaderMap};
3
3
+
use serde::Deserialize;
4
4
+
use serde_json::{Value, json};
5
5
+
6
6
+
use crate::{Error, JsonObject, record::RecordService};
7
7
+
8
8
+
#[derive(Debug, Clone)]
9
9
+
pub struct AuthStore {
10
10
+
pub(crate) token: String,
11
11
+
record: RecordModel,
12
12
+
}
13
13
+
14
14
+
#[derive(Debug, Clone)]
15
15
+
pub struct AuthRefreshBuilder<'a> {
16
16
+
pub(crate) record_service: RecordService<'a>,
17
17
+
pub(crate) expand_fields: Option<&'a str>,
18
18
+
pub(crate) filter_fields: Option<&'a str>,
19
19
+
}
20
20
+
21
21
+
#[derive(Debug, Clone)]
22
22
+
pub struct AuthWithPasswordBuilder<'a> {
23
23
+
pub(crate) record_service: RecordService<'a>,
24
24
+
pub(crate) identity: &'a str,
25
25
+
pub(crate) password: &'a str,
26
26
+
pub(crate) expand_fields: Option<&'a str>,
27
27
+
pub(crate) filter_fields: Option<&'a str>,
28
28
+
}
29
29
+
30
30
+
#[derive(Debug, Deserialize, Clone)]
31
31
+
pub struct RecordAuth {
32
32
+
token: String,
33
33
+
record: RecordModel,
34
34
+
}
35
35
+
36
36
+
#[derive(Debug, Deserialize, Clone)]
37
37
+
#[serde(transparent)]
38
38
+
pub struct RecordModel {
39
39
+
data: JsonObject,
40
40
+
}
41
41
+
42
42
+
#[cfg(target_arch = "wasm32")]
43
43
+
fn time_since_unix_epoch() -> u64 {
44
44
+
use web_time::{SystemTime, UNIX_EPOCH};
45
45
+
46
46
+
SystemTime::now()
47
47
+
.duration_since(UNIX_EPOCH)
48
48
+
.unwrap()
49
49
+
.as_secs()
50
50
+
}
51
51
+
52
52
+
#[cfg(not(target_arch = "wasm32"))]
53
53
+
fn time_since_unix_epoch() -> u64 {
54
54
+
use std::time::{SystemTime, UNIX_EPOCH};
55
55
+
56
56
+
SystemTime::now()
57
57
+
.duration_since(UNIX_EPOCH)
58
58
+
.unwrap()
59
59
+
.as_secs()
60
60
+
}
61
61
+
62
62
+
impl AuthStore {
63
63
+
pub fn is_valid(&self) -> bool {
64
64
+
let parts: Vec<&str> = self.token.split(".").collect();
65
65
+
if parts.len() != 3 {
66
66
+
return false;
67
67
+
}
68
68
+
69
69
+
let Ok(token_str) = String::from_utf8(BASE64_STANDARD_NO_PAD.decode(parts[1]).unwrap())
70
70
+
else {
71
71
+
return false;
72
72
+
};
73
73
+
let Ok(data) = serde_json::from_str::<JsonObject>(&token_str) else {
74
74
+
return false;
75
75
+
};
76
76
+
77
77
+
match data.get("exp") {
78
78
+
Some(Value::Number(exp)) => {
79
79
+
if let Some(exp) = exp.as_u64() {
80
80
+
exp > time_since_unix_epoch()
81
81
+
} else {
82
82
+
false
83
83
+
}
84
84
+
}
85
85
+
_ => false,
86
86
+
}
87
87
+
}
88
88
+
}
89
89
+
90
90
+
impl<'a> AuthRefreshBuilder<'a> {
91
91
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
92
92
+
self.expand_fields = Some(field_expression);
93
93
+
self
94
94
+
}
95
95
+
96
96
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
97
97
+
self.filter_fields = Some(field_expression);
98
98
+
self
99
99
+
}
100
100
+
101
101
+
pub async fn send(self) -> Result<RecordAuth, Error> {
102
102
+
let mut params = Vec::new();
103
103
+
if let Some(expand) = self.expand_fields {
104
104
+
params.push(("expand", expand));
105
105
+
}
106
106
+
if let Some(fields) = self.filter_fields {
107
107
+
params.push(("fields", fields));
108
108
+
}
109
109
+
110
110
+
let auth: RecordAuth = self
111
111
+
.record_service
112
112
+
.client
113
113
+
.send(
114
114
+
&format!(
115
115
+
"/api/collections/{}/auth-refresh",
116
116
+
self.record_service.collection
117
117
+
),
118
118
+
Method::POST,
119
119
+
HeaderMap::new(),
120
120
+
¶ms,
121
121
+
None::<&()>,
122
122
+
)
123
123
+
.await?;
124
124
+
self.record_service.client.with_auth_store(AuthStore {
125
125
+
token: auth.token.clone(),
126
126
+
record: auth.record.clone(),
127
127
+
});
128
128
+
debug_assert!({
129
129
+
let read = self.record_service.client.inner.read().unwrap();
130
130
+
read.auth_store.as_ref().unwrap().is_valid()
131
131
+
});
132
132
+
Ok(auth)
133
133
+
}
134
134
+
}
135
135
+
136
136
+
impl<'a> AuthWithPasswordBuilder<'a> {
137
137
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
138
138
+
self.expand_fields = Some(field_expression);
139
139
+
self
140
140
+
}
141
141
+
142
142
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
143
143
+
self.filter_fields = Some(field_expression);
144
144
+
self
145
145
+
}
146
146
+
147
147
+
pub async fn send(self) -> Result<RecordAuth, Error> {
148
148
+
let body = json!({"identity": self.identity, "password": self.password});
149
149
+
let mut params = Vec::new();
150
150
+
if let Some(expand) = self.expand_fields {
151
151
+
params.push(("expand", expand));
152
152
+
}
153
153
+
if let Some(fields) = self.filter_fields {
154
154
+
params.push(("fields", fields));
155
155
+
}
156
156
+
157
157
+
let auth: RecordAuth = self
158
158
+
.record_service
159
159
+
.client
160
160
+
.send(
161
161
+
&format!(
162
162
+
"/api/collections/{}/auth-with-password",
163
163
+
self.record_service.collection
164
164
+
),
165
165
+
Method::POST,
166
166
+
HeaderMap::new(),
167
167
+
¶ms,
168
168
+
Some(&body),
169
169
+
)
170
170
+
.await?;
171
171
+
self.record_service.client.with_auth_store(AuthStore {
172
172
+
token: auth.token.clone(),
173
173
+
record: auth.record.clone(),
174
174
+
});
175
175
+
debug_assert!({
176
176
+
let read = self.record_service.client.inner.read().unwrap();
177
177
+
read.auth_store.as_ref().unwrap().is_valid()
178
178
+
});
179
179
+
Ok(auth)
180
180
+
}
181
181
+
}
182
182
+
183
183
+
impl RecordModel {
184
184
+
pub fn as_object(&self) -> &'_ JsonObject {
185
185
+
&self.data
186
186
+
}
187
187
+
188
188
+
pub fn into_object(self) -> JsonObject {
189
189
+
self.data
190
190
+
}
191
191
+
}
+35
src/health.rs
···
1
1
+
use reqwest::{Method, header::HeaderMap};
2
2
+
use serde::Deserialize;
3
3
+
use serde_json::{Map, Value};
4
4
+
5
5
+
use crate::{Error, PocketBase};
6
6
+
7
7
+
#[derive(Clone, Debug)]
8
8
+
pub struct HealthService<'a> {
9
9
+
pub(super) client: &'a PocketBase,
10
10
+
pub(super) fields: Option<String>,
11
11
+
}
12
12
+
13
13
+
#[derive(Clone, Debug, Deserialize)]
14
14
+
pub struct HealthCheck {
15
15
+
pub message: String,
16
16
+
pub data: Map<String, Value>,
17
17
+
}
18
18
+
19
19
+
impl HealthService<'_> {
20
20
+
pub async fn check(self) -> Result<HealthCheck, Error> {
21
21
+
let mut params = Vec::new();
22
22
+
if let Some(fields) = self.fields {
23
23
+
params.push(("fields", fields));
24
24
+
}
25
25
+
self.client
26
26
+
.send(
27
27
+
"/api/health",
28
28
+
Method::GET,
29
29
+
HeaderMap::new(),
30
30
+
¶ms,
31
31
+
None::<&()>,
32
32
+
)
33
33
+
.await
34
34
+
}
35
35
+
}
+140
src/lib.rs
···
1
1
+
use std::sync::{Arc, RwLock};
2
2
+
3
3
+
use reqwest::{
4
4
+
Client, Method,
5
5
+
header::{HeaderMap, HeaderValue},
6
6
+
};
7
7
+
use serde::{Serialize, de::DeserializeOwned};
8
8
+
use serde_json::{Map, Value};
9
9
+
use thiserror::Error;
10
10
+
use url::{ParseError, Url};
11
11
+
12
12
+
pub mod auth;
13
13
+
pub mod health;
14
14
+
pub mod record;
15
15
+
16
16
+
use crate::{auth::AuthStore, health::HealthService, record::RecordService};
17
17
+
18
18
+
pub type Error = reqwest::Error;
19
19
+
20
20
+
pub type JsonObject = Map<String, Value>;
21
21
+
22
22
+
#[derive(Clone, Debug)]
23
23
+
pub struct PocketBase {
24
24
+
inner: Arc<RwLock<PocketBaseInner>>,
25
25
+
}
26
26
+
27
27
+
#[derive(Clone, Debug)]
28
28
+
struct PocketBaseInner {
29
29
+
reqwest: Client,
30
30
+
auth_store: Option<AuthStore>,
31
31
+
base_url: Url,
32
32
+
lang: String,
33
33
+
}
34
34
+
35
35
+
impl PocketBase {
36
36
+
pub fn auth_clear<'a>(&'a self) {
37
37
+
let mut write = self.inner.write().unwrap();
38
38
+
write.auth_store = None;
39
39
+
}
40
40
+
41
41
+
pub fn collection<'a>(&'a self, collection: &'a str) -> RecordService<'a> {
42
42
+
RecordService {
43
43
+
client: self,
44
44
+
collection,
45
45
+
}
46
46
+
}
47
47
+
48
48
+
pub fn health(&self) -> HealthService {
49
49
+
HealthService {
50
50
+
client: self,
51
51
+
fields: None,
52
52
+
}
53
53
+
}
54
54
+
55
55
+
pub fn lang(&self) -> String {
56
56
+
self.inner.read().unwrap().lang.clone()
57
57
+
}
58
58
+
59
59
+
pub fn new(base_url: &str) -> Result<Self, ParseError> {
60
60
+
let base_url = Url::parse(base_url)?;
61
61
+
let inner = PocketBaseInner {
62
62
+
reqwest: Client::new(),
63
63
+
base_url,
64
64
+
lang: "en_US".to_owned(),
65
65
+
auth_store: None,
66
66
+
};
67
67
+
Ok(Self {
68
68
+
inner: Arc::new(RwLock::new(inner)),
69
69
+
})
70
70
+
}
71
71
+
72
72
+
async fn send<Q, B, T>(
73
73
+
&self,
74
74
+
path: &str,
75
75
+
method: Method,
76
76
+
headers: HeaderMap,
77
77
+
query: &Q,
78
78
+
body: Option<&B>,
79
79
+
) -> Result<T, Error>
80
80
+
where
81
81
+
Q: Serialize + ?Sized,
82
82
+
B: Serialize + ?Sized,
83
83
+
T: DeserializeOwned,
84
84
+
{
85
85
+
// Get a reading lock on the inner data
86
86
+
let request = {
87
87
+
let read = self.inner.read().unwrap();
88
88
+
89
89
+
// Create the full URL
90
90
+
let mut url = read.base_url.clone();
91
91
+
url.set_path(path);
92
92
+
93
93
+
let mut headers = headers;
94
94
+
if !headers.contains_key("Authorization") && read.auth_store.is_some() {
95
95
+
headers.insert(
96
96
+
"Authorization",
97
97
+
HeaderValue::from_str(&read.auth_store.as_ref().unwrap().token).unwrap(),
98
98
+
);
99
99
+
}
100
100
+
if !headers.contains_key("Accept-Language") {
101
101
+
headers.insert(
102
102
+
"Accept-Language",
103
103
+
HeaderValue::from_str(&read.lang).unwrap(),
104
104
+
);
105
105
+
}
106
106
+
107
107
+
// Create the request to the PocketBase API
108
108
+
read.reqwest
109
109
+
.request(method, url)
110
110
+
.headers(headers)
111
111
+
.query(query)
112
112
+
};
113
113
+
114
114
+
// Add the body (as JSON) only if it's not None
115
115
+
let response = if let Some(body) = body {
116
116
+
request.json(body)
117
117
+
} else {
118
118
+
request
119
119
+
}
120
120
+
// Send the request and await the response
121
121
+
.send()
122
122
+
.await?;
123
123
+
124
124
+
// Parse the response body or return an error if something went wrong
125
125
+
response.error_for_status()?.json().await
126
126
+
}
127
127
+
128
128
+
fn with_auth_store(&self, auth: AuthStore) {
129
129
+
let mut write = self.inner.write().unwrap();
130
130
+
write.auth_store = Some(auth);
131
131
+
}
132
132
+
133
133
+
pub fn with_lang(self, lang: String) -> Self {
134
134
+
{
135
135
+
let mut write = self.inner.write().unwrap();
136
136
+
write.lang = lang;
137
137
+
}
138
138
+
self
139
139
+
}
140
140
+
}
+464
src/record.rs
···
1
1
+
use reqwest::{Method, header::HeaderMap};
2
2
+
use serde::{Deserialize, Serialize, de::DeserializeOwned};
3
3
+
use serde_json::{Map, Value};
4
4
+
5
5
+
use crate::{
6
6
+
Error, JsonObject, PocketBase,
7
7
+
auth::{AuthRefreshBuilder, AuthWithPasswordBuilder},
8
8
+
};
9
9
+
10
10
+
pub struct CreateRequestBuilder<'a, T: Serialize = JsonObject> {
11
11
+
record_service: RecordService<'a>,
12
12
+
body: T,
13
13
+
}
14
14
+
15
15
+
pub struct DeleteRequestBuilder<'a> {
16
16
+
record_service: RecordService<'a>,
17
17
+
id: &'a str,
18
18
+
}
19
19
+
20
20
+
#[derive(Clone, Debug)]
21
21
+
pub struct ListRequestBuilder<'a> {
22
22
+
record_service: RecordService<'a>,
23
23
+
expand_fields: Option<&'a str>,
24
24
+
filter_fields: Option<&'a str>,
25
25
+
filter_records: Option<&'a str>,
26
26
+
page: usize,
27
27
+
per_page: usize,
28
28
+
skip_total: Option<bool>,
29
29
+
sort: Option<&'a str>,
30
30
+
}
31
31
+
32
32
+
#[derive(Clone, Debug)]
33
33
+
pub struct FullListRequestBuilder<'a> {
34
34
+
record_service: RecordService<'a>,
35
35
+
batch: Option<usize>,
36
36
+
expand_fields: Option<&'a str>,
37
37
+
filter_fields: Option<&'a str>,
38
38
+
filter_records: Option<&'a str>,
39
39
+
skip_total: Option<bool>,
40
40
+
order_by: Option<&'a str>,
41
41
+
}
42
42
+
43
43
+
#[derive(Clone, Debug)]
44
44
+
pub struct RecordService<'a> {
45
45
+
pub(super) client: &'a PocketBase,
46
46
+
pub(super) collection: &'a str,
47
47
+
}
48
48
+
49
49
+
#[derive(Clone, Debug, Default, Deserialize, Eq, Serialize, PartialEq)]
50
50
+
#[serde(rename_all = "camelCase")]
51
51
+
pub struct ResultList<T> {
52
52
+
items: Vec<T>,
53
53
+
page: usize,
54
54
+
per_page: usize,
55
55
+
total_items: isize,
56
56
+
total_pages: isize,
57
57
+
}
58
58
+
59
59
+
#[derive(Clone, Debug)]
60
60
+
pub struct ViewRequestBuilder<'a> {
61
61
+
record_service: RecordService<'a>,
62
62
+
expand_fields: Option<&'a str>,
63
63
+
filter_fields: Option<&'a str>,
64
64
+
id: &'a str,
65
65
+
}
66
66
+
67
67
+
#[derive(Clone, Debug)]
68
68
+
pub struct UpdateRequestBuilder<'a, T: Serialize = JsonObject> {
69
69
+
record_service: RecordService<'a>,
70
70
+
body: T,
71
71
+
expand_fields: Option<&'a str>,
72
72
+
filter_fields: Option<&'a str>,
73
73
+
id: &'a str,
74
74
+
}
75
75
+
76
76
+
impl<'a, T: Serialize + Clone> CreateRequestBuilder<'a, T> {
77
77
+
pub fn object<X: Serialize + Clone>(self, obj: X) -> CreateRequestBuilder<'a, X> {
78
78
+
CreateRequestBuilder {
79
79
+
record_service: self.record_service,
80
80
+
body: obj,
81
81
+
}
82
82
+
}
83
83
+
84
84
+
pub async fn send<R: DeserializeOwned>(self) -> Result<R, Error> {
85
85
+
let params: &[()] = &[];
86
86
+
87
87
+
self.record_service
88
88
+
.client
89
89
+
.send(
90
90
+
&format!(
91
91
+
"/api/collections/{}/records",
92
92
+
self.record_service.collection
93
93
+
),
94
94
+
Method::POST,
95
95
+
HeaderMap::new(),
96
96
+
¶ms,
97
97
+
Some(&self.body),
98
98
+
)
99
99
+
.await
100
100
+
}
101
101
+
}
102
102
+
103
103
+
impl CreateRequestBuilder<'_, JsonObject> {
104
104
+
pub fn fields<Iter: IntoIterator<Item = (String, Value)>>(mut self, patch: Iter) -> Self {
105
105
+
self.body.extend(patch);
106
106
+
self
107
107
+
}
108
108
+
}
109
109
+
110
110
+
impl DeleteRequestBuilder<'_> {
111
111
+
pub async fn send<T: DeserializeOwned>(self) -> Result<T, Error> {
112
112
+
let params: &[()] = &[];
113
113
+
self.record_service
114
114
+
.client
115
115
+
.send(
116
116
+
&format!(
117
117
+
"/api/collections/{}/records/{}",
118
118
+
self.record_service.collection, self.id
119
119
+
),
120
120
+
Method::DELETE,
121
121
+
HeaderMap::new(),
122
122
+
¶ms,
123
123
+
None::<&()>,
124
124
+
)
125
125
+
.await
126
126
+
}
127
127
+
}
128
128
+
129
129
+
impl<'a> FullListRequestBuilder<'a> {
130
130
+
pub fn batch_size(mut self, batch: usize) -> Self {
131
131
+
self.batch = Some(batch);
132
132
+
self
133
133
+
}
134
134
+
135
135
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
136
136
+
self.expand_fields = Some(field_expression);
137
137
+
self
138
138
+
}
139
139
+
140
140
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
141
141
+
self.filter_fields = Some(field_expression);
142
142
+
self
143
143
+
}
144
144
+
145
145
+
pub fn filter_records(mut self, filter_expression: &'a str) -> Self {
146
146
+
self.filter_records = Some(filter_expression);
147
147
+
self
148
148
+
}
149
149
+
150
150
+
pub fn skip_total(mut self, skip_total: bool) -> Self {
151
151
+
self.skip_total = Some(skip_total);
152
152
+
self
153
153
+
}
154
154
+
155
155
+
pub fn order_by(mut self, sort_expression: &'a str) -> Self {
156
156
+
self.order_by = Some(sort_expression);
157
157
+
self
158
158
+
}
159
159
+
160
160
+
pub async fn send<T: DeserializeOwned>(self) -> Result<Vec<T>, Error> {
161
161
+
let mut list = ListRequestBuilder {
162
162
+
record_service: self.record_service,
163
163
+
expand_fields: self.expand_fields,
164
164
+
filter_fields: self.filter_fields,
165
165
+
filter_records: self.filter_records,
166
166
+
page: 1,
167
167
+
per_page: self.batch.unwrap_or(500),
168
168
+
skip_total: Some(true),
169
169
+
sort: self.order_by,
170
170
+
};
171
171
+
172
172
+
let mut ret = Vec::new();
173
173
+
loop {
174
174
+
let page = list.clone().send().await?;
175
175
+
let persist = page.items.len() == list.per_page;
176
176
+
ret.extend(page.items);
177
177
+
if !persist {
178
178
+
break;
179
179
+
}
180
180
+
list.page += 1;
181
181
+
}
182
182
+
Ok(ret)
183
183
+
}
184
184
+
}
185
185
+
186
186
+
impl<'a> ListRequestBuilder<'a> {
187
187
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
188
188
+
self.expand_fields = Some(field_expression);
189
189
+
self
190
190
+
}
191
191
+
192
192
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
193
193
+
self.filter_fields = Some(field_expression);
194
194
+
self
195
195
+
}
196
196
+
197
197
+
pub fn filter(mut self, filter: &'a str) -> Self {
198
198
+
self.filter_records = Some(filter);
199
199
+
self
200
200
+
}
201
201
+
202
202
+
pub fn skip_total(mut self, skip_total: bool) -> Self {
203
203
+
self.skip_total = Some(skip_total);
204
204
+
self
205
205
+
}
206
206
+
207
207
+
pub fn sort(mut self, sort: &'a str) -> Self {
208
208
+
self.sort = Some(sort);
209
209
+
self
210
210
+
}
211
211
+
212
212
+
pub async fn send<T: DeserializeOwned>(self) -> Result<ResultList<T>, Error> {
213
213
+
let mut storage = vec![self.page.to_string(), self.per_page.to_string()];
214
214
+
if let Some(skip_total) = self.skip_total {
215
215
+
storage.push(skip_total.to_string());
216
216
+
}
217
217
+
let mut params: Vec<(&str, &str)> = vec![("page", &storage[0]), ("perPage", &storage[1])];
218
218
+
if let Some(filter) = self.filter_records {
219
219
+
params.push(("filter", filter));
220
220
+
}
221
221
+
if let Some(sort) = self.sort {
222
222
+
params.push(("sort", sort));
223
223
+
}
224
224
+
if let Some(expand) = self.expand_fields {
225
225
+
params.push(("expand", expand));
226
226
+
}
227
227
+
if let Some(fields) = self.filter_fields {
228
228
+
params.push(("fields", fields));
229
229
+
}
230
230
+
if self.skip_total.is_some() {
231
231
+
params.push(("skipTotal", &storage[2]));
232
232
+
}
233
233
+
234
234
+
self.record_service
235
235
+
.client
236
236
+
.send(
237
237
+
&format!(
238
238
+
"/api/collections/{}/records",
239
239
+
self.record_service.collection
240
240
+
),
241
241
+
Method::GET,
242
242
+
HeaderMap::new(),
243
243
+
¶ms,
244
244
+
None::<&()>,
245
245
+
)
246
246
+
.await
247
247
+
}
248
248
+
}
249
249
+
250
250
+
impl<'a> RecordService<'a> {
251
251
+
pub fn auth_refresh(&self) -> AuthRefreshBuilder<'a> {
252
252
+
AuthRefreshBuilder {
253
253
+
record_service: self.clone(),
254
254
+
expand_fields: None,
255
255
+
filter_fields: None,
256
256
+
}
257
257
+
}
258
258
+
259
259
+
pub fn auth_with_password(
260
260
+
&self,
261
261
+
identity: &'a str,
262
262
+
password: &'a str,
263
263
+
) -> AuthWithPasswordBuilder<'a> {
264
264
+
AuthWithPasswordBuilder {
265
265
+
record_service: self.clone(),
266
266
+
identity,
267
267
+
password,
268
268
+
expand_fields: None,
269
269
+
filter_fields: None,
270
270
+
}
271
271
+
}
272
272
+
273
273
+
pub fn create(&self) -> CreateRequestBuilder<'a> {
274
274
+
CreateRequestBuilder {
275
275
+
record_service: self.clone(),
276
276
+
body: Map::new(),
277
277
+
}
278
278
+
}
279
279
+
280
280
+
pub fn delete(&self, id: &'a str) -> DeleteRequestBuilder<'a> {
281
281
+
DeleteRequestBuilder {
282
282
+
record_service: self.clone(),
283
283
+
id,
284
284
+
}
285
285
+
}
286
286
+
287
287
+
pub fn get_full_list(&self) -> FullListRequestBuilder<'a> {
288
288
+
FullListRequestBuilder {
289
289
+
record_service: self.clone(),
290
290
+
batch: None,
291
291
+
filter_records: None,
292
292
+
order_by: None,
293
293
+
expand_fields: None,
294
294
+
filter_fields: None,
295
295
+
skip_total: None,
296
296
+
}
297
297
+
}
298
298
+
299
299
+
pub fn get_list(&self, page: usize, per_page: usize) -> ListRequestBuilder<'a> {
300
300
+
ListRequestBuilder {
301
301
+
record_service: self.clone(),
302
302
+
page,
303
303
+
per_page,
304
304
+
filter_records: None,
305
305
+
sort: None,
306
306
+
expand_fields: None,
307
307
+
filter_fields: None,
308
308
+
skip_total: None,
309
309
+
}
310
310
+
}
311
311
+
312
312
+
pub fn get_one(&'a self, id: &'a str) -> ViewRequestBuilder<'a> {
313
313
+
ViewRequestBuilder {
314
314
+
record_service: self.clone(),
315
315
+
id,
316
316
+
expand_fields: None,
317
317
+
filter_fields: None,
318
318
+
}
319
319
+
}
320
320
+
321
321
+
pub fn update(&self, id: &'a str) -> UpdateRequestBuilder<'a> {
322
322
+
UpdateRequestBuilder {
323
323
+
record_service: self.clone(),
324
324
+
id,
325
325
+
expand_fields: None,
326
326
+
filter_fields: None,
327
327
+
body: Map::new(),
328
328
+
}
329
329
+
}
330
330
+
}
331
331
+
332
332
+
impl<T> ResultList<T> {
333
333
+
pub fn items(&self) -> &[T] {
334
334
+
&self.items
335
335
+
}
336
336
+
337
337
+
pub fn into_vec(self) -> Vec<T> {
338
338
+
self.items
339
339
+
}
340
340
+
341
341
+
pub fn page(&self) -> usize {
342
342
+
self.page
343
343
+
}
344
344
+
345
345
+
pub fn per_page(&self) -> usize {
346
346
+
self.per_page
347
347
+
}
348
348
+
}
349
349
+
350
350
+
impl<T> IntoIterator for ResultList<T> {
351
351
+
type Item = T;
352
352
+
type IntoIter = std::vec::IntoIter<T>;
353
353
+
354
354
+
fn into_iter(self) -> Self::IntoIter {
355
355
+
self.items.into_iter()
356
356
+
}
357
357
+
}
358
358
+
359
359
+
impl<'a, T> IntoIterator for &'a ResultList<T> {
360
360
+
type Item = &'a T;
361
361
+
type IntoIter = std::slice::Iter<'a, T>;
362
362
+
363
363
+
fn into_iter(self) -> Self::IntoIter {
364
364
+
self.items.iter()
365
365
+
}
366
366
+
}
367
367
+
368
368
+
impl<'a, T> IntoIterator for &'a mut ResultList<T> {
369
369
+
type Item = &'a mut T;
370
370
+
type IntoIter = std::slice::IterMut<'a, T>;
371
371
+
372
372
+
fn into_iter(self) -> Self::IntoIter {
373
373
+
self.items.iter_mut()
374
374
+
}
375
375
+
}
376
376
+
377
377
+
impl<'a> ViewRequestBuilder<'a> {
378
378
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
379
379
+
self.expand_fields = Some(field_expression);
380
380
+
self
381
381
+
}
382
382
+
383
383
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
384
384
+
self.filter_fields = Some(field_expression);
385
385
+
self
386
386
+
}
387
387
+
388
388
+
pub async fn send<T: DeserializeOwned>(self) -> Result<T, Error> {
389
389
+
let mut params = Vec::new();
390
390
+
if let Some(expand) = self.expand_fields {
391
391
+
params.push(("expand", expand));
392
392
+
}
393
393
+
if let Some(fields) = self.filter_fields {
394
394
+
params.push(("fields", fields));
395
395
+
}
396
396
+
397
397
+
self.record_service
398
398
+
.client
399
399
+
.send(
400
400
+
&format!(
401
401
+
"/api/collections/{}/records/{}",
402
402
+
self.record_service.collection, self.id
403
403
+
),
404
404
+
Method::GET,
405
405
+
HeaderMap::new(),
406
406
+
¶ms,
407
407
+
None::<&()>,
408
408
+
)
409
409
+
.await
410
410
+
}
411
411
+
}
412
412
+
413
413
+
impl<'a, T: Serialize> UpdateRequestBuilder<'a, T> {
414
414
+
pub fn expand_fields(mut self, field_expression: &'a str) -> Self {
415
415
+
self.expand_fields = Some(field_expression);
416
416
+
self
417
417
+
}
418
418
+
419
419
+
pub fn filter_fields(mut self, field_expression: &'a str) -> Self {
420
420
+
self.filter_fields = Some(field_expression);
421
421
+
self
422
422
+
}
423
423
+
424
424
+
pub fn object<X: Serialize>(self, obj: X) -> UpdateRequestBuilder<'a, X> {
425
425
+
UpdateRequestBuilder {
426
426
+
record_service: self.record_service,
427
427
+
body: obj,
428
428
+
expand_fields: self.expand_fields,
429
429
+
filter_fields: self.filter_fields,
430
430
+
id: self.id,
431
431
+
}
432
432
+
}
433
433
+
434
434
+
pub async fn send<R: DeserializeOwned>(self) -> Result<R, Error> {
435
435
+
let mut params = Vec::new();
436
436
+
if let Some(expand) = self.expand_fields {
437
437
+
params.push(("expand", expand));
438
438
+
}
439
439
+
if let Some(fields) = self.filter_fields {
440
440
+
params.push(("fields", fields));
441
441
+
}
442
442
+
443
443
+
self.record_service
444
444
+
.client
445
445
+
.send(
446
446
+
&format!(
447
447
+
"/api/collections/{}/records/{}",
448
448
+
self.record_service.collection, self.id
449
449
+
),
450
450
+
Method::PATCH,
451
451
+
HeaderMap::new(),
452
452
+
¶ms,
453
453
+
Some(&self.body),
454
454
+
)
455
455
+
.await
456
456
+
}
457
457
+
}
458
458
+
459
459
+
impl UpdateRequestBuilder<'_, JsonObject> {
460
460
+
pub fn fields<Iter: IntoIterator<Item = (String, Value)>>(mut self, patch: Iter) -> Self {
461
461
+
self.body.extend(patch);
462
462
+
self
463
463
+
}
464
464
+
}