appwrite 16.1.0 → 18.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/appwrite/client.rb +2 -2
- data/lib/appwrite/enums/credit_card.rb +1 -1
- data/lib/appwrite/enums/execution_method.rb +1 -0
- data/lib/appwrite/enums/index_type.rb +1 -0
- data/lib/appwrite/models/attribute_line.rb +67 -0
- data/lib/appwrite/models/attribute_point.rb +67 -0
- data/lib/appwrite/models/attribute_polygon.rb +67 -0
- data/lib/appwrite/models/column_boolean.rb +67 -0
- data/lib/appwrite/models/column_datetime.rb +72 -0
- data/lib/appwrite/models/column_email.rb +72 -0
- data/lib/appwrite/models/column_enum.rb +77 -0
- data/lib/appwrite/models/column_float.rb +77 -0
- data/lib/appwrite/models/column_index.rb +72 -0
- data/lib/appwrite/models/column_index_list.rb +32 -0
- data/lib/appwrite/models/column_integer.rb +77 -0
- data/lib/appwrite/models/column_ip.rb +72 -0
- data/lib/appwrite/models/column_line.rb +67 -0
- data/lib/appwrite/models/column_list.rb +32 -0
- data/lib/appwrite/models/column_point.rb +67 -0
- data/lib/appwrite/models/column_polygon.rb +67 -0
- data/lib/appwrite/models/column_relationship.rb +92 -0
- data/lib/appwrite/models/column_string.rb +77 -0
- data/lib/appwrite/models/column_url.rb +72 -0
- data/lib/appwrite/models/database.rb +8 -3
- data/lib/appwrite/models/execution.rb +5 -0
- data/lib/appwrite/models/index.rb +18 -13
- data/lib/appwrite/models/row.rb +66 -0
- data/lib/appwrite/models/row_list.rb +36 -0
- data/lib/appwrite/models/table.rb +72 -0
- data/lib/appwrite/models/table_list.rb +32 -0
- data/lib/appwrite/query.rb +92 -0
- data/lib/appwrite/services/account.rb +15 -48
- data/lib/appwrite/services/avatars.rb +1 -8
- data/lib/appwrite/services/databases.rb +519 -120
- data/lib/appwrite/services/functions.rb +1 -27
- data/lib/appwrite/services/graphql.rb +0 -2
- data/lib/appwrite/services/health.rb +0 -22
- data/lib/appwrite/services/locale.rb +0 -8
- data/lib/appwrite/services/messaging.rb +0 -46
- data/lib/appwrite/services/sites.rb +0 -25
- data/lib/appwrite/services/storage.rb +0 -13
- data/lib/appwrite/services/tables_db.rb +2621 -0
- data/lib/appwrite/services/teams.rb +0 -13
- data/lib/appwrite/services/tokens.rb +0 -5
- data/lib/appwrite/services/users.rb +0 -42
- data/lib/appwrite.rb +24 -0
- metadata +26 -2
@@ -7,6 +7,9 @@ module Appwrite
|
|
7
7
|
@client = client
|
8
8
|
end
|
9
9
|
|
10
|
+
#
|
11
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.list` instead.
|
12
|
+
#
|
10
13
|
# Get a list of all databases from the current Appwrite project. You can use
|
11
14
|
# the search parameter to filter your results.
|
12
15
|
#
|
@@ -34,7 +37,9 @@ module Appwrite
|
|
34
37
|
)
|
35
38
|
end
|
36
39
|
|
37
|
-
|
40
|
+
#
|
41
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.create` instead.
|
42
|
+
#
|
38
43
|
# Create a new Database.
|
39
44
|
#
|
40
45
|
#
|
@@ -73,7 +78,9 @@ module Appwrite
|
|
73
78
|
)
|
74
79
|
end
|
75
80
|
|
76
|
-
|
81
|
+
#
|
82
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.get` instead.
|
83
|
+
#
|
77
84
|
# Get a database by its unique ID. This endpoint response returns a JSON
|
78
85
|
# object with the database metadata.
|
79
86
|
#
|
@@ -103,7 +110,9 @@ module Appwrite
|
|
103
110
|
)
|
104
111
|
end
|
105
112
|
|
106
|
-
|
113
|
+
#
|
114
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.update` instead.
|
115
|
+
#
|
107
116
|
# Update a database by its unique ID.
|
108
117
|
#
|
109
118
|
# @param [String] database_id Database ID.
|
@@ -141,7 +150,9 @@ module Appwrite
|
|
141
150
|
)
|
142
151
|
end
|
143
152
|
|
144
|
-
|
153
|
+
#
|
154
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.delete` instead.
|
155
|
+
#
|
145
156
|
# Delete a database by its unique ID. Only API keys with with databases.write
|
146
157
|
# scope can delete a database.
|
147
158
|
#
|
@@ -171,7 +182,9 @@ module Appwrite
|
|
171
182
|
)
|
172
183
|
end
|
173
184
|
|
174
|
-
|
185
|
+
#
|
186
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.listTables` instead.
|
187
|
+
#
|
175
188
|
# Get a list of all collections that belong to the provided databaseId. You
|
176
189
|
# can use the search parameter to filter your results.
|
177
190
|
#
|
@@ -205,7 +218,9 @@ module Appwrite
|
|
205
218
|
)
|
206
219
|
end
|
207
220
|
|
208
|
-
|
221
|
+
#
|
222
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createTable` instead.
|
223
|
+
#
|
209
224
|
# Create a new Collection. Before using this route, you should create a new
|
210
225
|
# database resource using either a [server
|
211
226
|
# integration](https://appwrite.io/docs/server/databases#databasesCreateCollection)
|
@@ -256,7 +271,9 @@ module Appwrite
|
|
256
271
|
)
|
257
272
|
end
|
258
273
|
|
259
|
-
|
274
|
+
#
|
275
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.getTable` instead.
|
276
|
+
#
|
260
277
|
# Get a collection by its unique ID. This endpoint response returns a JSON
|
261
278
|
# object with the collection metadata.
|
262
279
|
#
|
@@ -292,7 +309,9 @@ module Appwrite
|
|
292
309
|
)
|
293
310
|
end
|
294
311
|
|
295
|
-
|
312
|
+
#
|
313
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateTable` instead.
|
314
|
+
#
|
296
315
|
# Update a collection by its unique ID.
|
297
316
|
#
|
298
317
|
# @param [String] database_id Database ID.
|
@@ -340,7 +359,9 @@ module Appwrite
|
|
340
359
|
)
|
341
360
|
end
|
342
361
|
|
343
|
-
|
362
|
+
#
|
363
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.deleteTable` instead.
|
364
|
+
#
|
344
365
|
# Delete a collection by its unique ID. Only users with write permissions
|
345
366
|
# have access to delete this resource.
|
346
367
|
#
|
@@ -376,11 +397,13 @@ module Appwrite
|
|
376
397
|
)
|
377
398
|
end
|
378
399
|
|
379
|
-
|
400
|
+
#
|
401
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.listColumns` instead.
|
402
|
+
#
|
380
403
|
# List attributes in the collection.
|
381
404
|
#
|
382
405
|
# @param [String] database_id Database ID.
|
383
|
-
# @param [String] collection_id Collection ID.
|
406
|
+
# @param [String] collection_id Collection ID.
|
384
407
|
# @param [Array] queries Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: key, type, size, required, array, status, error
|
385
408
|
#
|
386
409
|
# @return [AttributeList]
|
@@ -413,12 +436,14 @@ module Appwrite
|
|
413
436
|
)
|
414
437
|
end
|
415
438
|
|
416
|
-
|
439
|
+
#
|
440
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createBooleanColumn` instead.
|
441
|
+
#
|
417
442
|
# Create a boolean attribute.
|
418
443
|
#
|
419
444
|
#
|
420
445
|
# @param [String] database_id Database ID.
|
421
|
-
# @param [String] collection_id Collection ID. You can create a new
|
446
|
+
# @param [String] collection_id Collection ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
422
447
|
# @param [String] key Attribute Key.
|
423
448
|
# @param [] required Is attribute required?
|
424
449
|
# @param [] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
@@ -466,12 +491,14 @@ module Appwrite
|
|
466
491
|
)
|
467
492
|
end
|
468
493
|
|
469
|
-
|
494
|
+
#
|
495
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateBooleanColumn` instead.
|
496
|
+
#
|
470
497
|
# Update a boolean attribute. Changing the `default` value will not update
|
471
498
|
# already existing documents.
|
472
499
|
#
|
473
500
|
# @param [String] database_id Database ID.
|
474
|
-
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#
|
501
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).
|
475
502
|
# @param [String] key Attribute Key.
|
476
503
|
# @param [] required Is attribute required?
|
477
504
|
# @param [] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
@@ -523,11 +550,13 @@ module Appwrite
|
|
523
550
|
)
|
524
551
|
end
|
525
552
|
|
526
|
-
|
553
|
+
#
|
554
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createDatetimeColumn` instead.
|
555
|
+
#
|
527
556
|
# Create a date time attribute according to the ISO 8601 standard.
|
528
557
|
#
|
529
558
|
# @param [String] database_id Database ID.
|
530
|
-
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#
|
559
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).
|
531
560
|
# @param [String] key Attribute Key.
|
532
561
|
# @param [] required Is attribute required?
|
533
562
|
# @param [String] default Default value for the attribute in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.
|
@@ -575,12 +604,14 @@ module Appwrite
|
|
575
604
|
)
|
576
605
|
end
|
577
606
|
|
578
|
-
|
607
|
+
#
|
608
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateDatetimeColumn` instead.
|
609
|
+
#
|
579
610
|
# Update a date time attribute. Changing the `default` value will not update
|
580
611
|
# already existing documents.
|
581
612
|
#
|
582
613
|
# @param [String] database_id Database ID.
|
583
|
-
# @param [String] collection_id Collection ID.
|
614
|
+
# @param [String] collection_id Collection ID.
|
584
615
|
# @param [String] key Attribute Key.
|
585
616
|
# @param [] required Is attribute required?
|
586
617
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
@@ -632,12 +663,14 @@ module Appwrite
|
|
632
663
|
)
|
633
664
|
end
|
634
665
|
|
635
|
-
|
666
|
+
#
|
667
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createEmailColumn` instead.
|
668
|
+
#
|
636
669
|
# Create an email attribute.
|
637
670
|
#
|
638
671
|
#
|
639
672
|
# @param [String] database_id Database ID.
|
640
|
-
# @param [String] collection_id Collection ID.
|
673
|
+
# @param [String] collection_id Collection ID.
|
641
674
|
# @param [String] key Attribute Key.
|
642
675
|
# @param [] required Is attribute required?
|
643
676
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
@@ -685,17 +718,19 @@ module Appwrite
|
|
685
718
|
)
|
686
719
|
end
|
687
720
|
|
688
|
-
|
721
|
+
#
|
722
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateEmailColumn` instead.
|
723
|
+
#
|
689
724
|
# Update an email attribute. Changing the `default` value will not update
|
690
725
|
# already existing documents.
|
691
726
|
#
|
692
727
|
#
|
693
728
|
# @param [String] database_id Database ID.
|
694
|
-
# @param [String] collection_id Collection ID.
|
729
|
+
# @param [String] collection_id Collection ID.
|
695
730
|
# @param [String] key Attribute Key.
|
696
731
|
# @param [] required Is attribute required?
|
697
732
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
698
|
-
# @param [String] new_key New
|
733
|
+
# @param [String] new_key New Attribute Key.
|
699
734
|
#
|
700
735
|
# @return [AttributeEmail]
|
701
736
|
def update_email_attribute(database_id:, collection_id:, key:, required:, default:, new_key: nil)
|
@@ -743,15 +778,17 @@ module Appwrite
|
|
743
778
|
)
|
744
779
|
end
|
745
780
|
|
746
|
-
|
747
|
-
#
|
748
|
-
#
|
781
|
+
#
|
782
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createEnumColumn` instead.
|
783
|
+
#
|
784
|
+
# Create an enum attribute. The `elements` param acts as a white-list of
|
785
|
+
# accepted values for this attribute.
|
749
786
|
#
|
750
787
|
#
|
751
788
|
# @param [String] database_id Database ID.
|
752
|
-
# @param [String] collection_id Collection ID.
|
789
|
+
# @param [String] collection_id Collection ID.
|
753
790
|
# @param [String] key Attribute Key.
|
754
|
-
# @param [Array] elements Array of
|
791
|
+
# @param [Array] elements Array of enum values.
|
755
792
|
# @param [] required Is attribute required?
|
756
793
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
757
794
|
# @param [] array Is attribute an array?
|
@@ -803,18 +840,20 @@ module Appwrite
|
|
803
840
|
)
|
804
841
|
end
|
805
842
|
|
806
|
-
|
843
|
+
#
|
844
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateEnumColumn` instead.
|
845
|
+
#
|
807
846
|
# Update an enum attribute. Changing the `default` value will not update
|
808
847
|
# already existing documents.
|
809
848
|
#
|
810
849
|
#
|
811
850
|
# @param [String] database_id Database ID.
|
812
|
-
# @param [String] collection_id Collection ID.
|
851
|
+
# @param [String] collection_id Collection ID.
|
813
852
|
# @param [String] key Attribute Key.
|
814
|
-
# @param [Array] elements
|
853
|
+
# @param [Array] elements Updated list of enum values.
|
815
854
|
# @param [] required Is attribute required?
|
816
855
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
817
|
-
# @param [String] new_key New
|
856
|
+
# @param [String] new_key New Attribute Key.
|
818
857
|
#
|
819
858
|
# @return [AttributeEnum]
|
820
859
|
def update_enum_attribute(database_id:, collection_id:, key:, elements:, required:, default:, new_key: nil)
|
@@ -867,18 +906,20 @@ module Appwrite
|
|
867
906
|
)
|
868
907
|
end
|
869
908
|
|
870
|
-
|
909
|
+
#
|
910
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createFloatColumn` instead.
|
911
|
+
#
|
871
912
|
# Create a float attribute. Optionally, minimum and maximum values can be
|
872
913
|
# provided.
|
873
914
|
#
|
874
915
|
#
|
875
916
|
# @param [String] database_id Database ID.
|
876
|
-
# @param [String] collection_id Collection ID.
|
917
|
+
# @param [String] collection_id Collection ID.
|
877
918
|
# @param [String] key Attribute Key.
|
878
919
|
# @param [] required Is attribute required?
|
879
|
-
# @param [Float] min Minimum value
|
880
|
-
# @param [Float] max Maximum value
|
881
|
-
# @param [Float] default Default value
|
920
|
+
# @param [Float] min Minimum value.
|
921
|
+
# @param [Float] max Maximum value.
|
922
|
+
# @param [Float] default Default value. Cannot be set when required.
|
882
923
|
# @param [] array Is attribute an array?
|
883
924
|
#
|
884
925
|
# @return [AttributeFloat]
|
@@ -925,19 +966,21 @@ module Appwrite
|
|
925
966
|
)
|
926
967
|
end
|
927
968
|
|
928
|
-
|
969
|
+
#
|
970
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateFloatColumn` instead.
|
971
|
+
#
|
929
972
|
# Update a float attribute. Changing the `default` value will not update
|
930
973
|
# already existing documents.
|
931
974
|
#
|
932
975
|
#
|
933
976
|
# @param [String] database_id Database ID.
|
934
|
-
# @param [String] collection_id Collection ID.
|
977
|
+
# @param [String] collection_id Collection ID.
|
935
978
|
# @param [String] key Attribute Key.
|
936
979
|
# @param [] required Is attribute required?
|
937
|
-
# @param [Float] default Default value
|
938
|
-
# @param [Float] min Minimum value
|
939
|
-
# @param [Float] max Maximum value
|
940
|
-
# @param [String] new_key New
|
980
|
+
# @param [Float] default Default value. Cannot be set when required.
|
981
|
+
# @param [Float] min Minimum value.
|
982
|
+
# @param [Float] max Maximum value.
|
983
|
+
# @param [String] new_key New Attribute Key.
|
941
984
|
#
|
942
985
|
# @return [AttributeFloat]
|
943
986
|
def update_float_attribute(database_id:, collection_id:, key:, required:, default:, min: nil, max: nil, new_key: nil)
|
@@ -987,18 +1030,20 @@ module Appwrite
|
|
987
1030
|
)
|
988
1031
|
end
|
989
1032
|
|
990
|
-
|
1033
|
+
#
|
1034
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createIntegerColumn` instead.
|
1035
|
+
#
|
991
1036
|
# Create an integer attribute. Optionally, minimum and maximum values can be
|
992
1037
|
# provided.
|
993
1038
|
#
|
994
1039
|
#
|
995
1040
|
# @param [String] database_id Database ID.
|
996
|
-
# @param [String] collection_id Collection ID.
|
1041
|
+
# @param [String] collection_id Collection ID.
|
997
1042
|
# @param [String] key Attribute Key.
|
998
1043
|
# @param [] required Is attribute required?
|
999
|
-
# @param [Integer] min Minimum value
|
1000
|
-
# @param [Integer] max Maximum value
|
1001
|
-
# @param [Integer] default Default value
|
1044
|
+
# @param [Integer] min Minimum value
|
1045
|
+
# @param [Integer] max Maximum value
|
1046
|
+
# @param [Integer] default Default value. Cannot be set when attribute is required.
|
1002
1047
|
# @param [] array Is attribute an array?
|
1003
1048
|
#
|
1004
1049
|
# @return [AttributeInteger]
|
@@ -1045,19 +1090,21 @@ module Appwrite
|
|
1045
1090
|
)
|
1046
1091
|
end
|
1047
1092
|
|
1048
|
-
|
1093
|
+
#
|
1094
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateIntegerColumn` instead.
|
1095
|
+
#
|
1049
1096
|
# Update an integer attribute. Changing the `default` value will not update
|
1050
1097
|
# already existing documents.
|
1051
1098
|
#
|
1052
1099
|
#
|
1053
1100
|
# @param [String] database_id Database ID.
|
1054
|
-
# @param [String] collection_id Collection ID.
|
1101
|
+
# @param [String] collection_id Collection ID.
|
1055
1102
|
# @param [String] key Attribute Key.
|
1056
1103
|
# @param [] required Is attribute required?
|
1057
|
-
# @param [Integer] default Default value
|
1058
|
-
# @param [Integer] min Minimum value
|
1059
|
-
# @param [Integer] max Maximum value
|
1060
|
-
# @param [String] new_key New
|
1104
|
+
# @param [Integer] default Default value. Cannot be set when attribute is required.
|
1105
|
+
# @param [Integer] min Minimum value
|
1106
|
+
# @param [Integer] max Maximum value
|
1107
|
+
# @param [String] new_key New Attribute Key.
|
1061
1108
|
#
|
1062
1109
|
# @return [AttributeInteger]
|
1063
1110
|
def update_integer_attribute(database_id:, collection_id:, key:, required:, default:, min: nil, max: nil, new_key: nil)
|
@@ -1107,15 +1154,17 @@ module Appwrite
|
|
1107
1154
|
)
|
1108
1155
|
end
|
1109
1156
|
|
1110
|
-
|
1157
|
+
#
|
1158
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createIpColumn` instead.
|
1159
|
+
#
|
1111
1160
|
# Create IP address attribute.
|
1112
1161
|
#
|
1113
1162
|
#
|
1114
1163
|
# @param [String] database_id Database ID.
|
1115
|
-
# @param [String] collection_id Collection ID.
|
1164
|
+
# @param [String] collection_id Collection ID.
|
1116
1165
|
# @param [String] key Attribute Key.
|
1117
1166
|
# @param [] required Is attribute required?
|
1118
|
-
# @param [String] default Default value
|
1167
|
+
# @param [String] default Default value. Cannot be set when attribute is required.
|
1119
1168
|
# @param [] array Is attribute an array?
|
1120
1169
|
#
|
1121
1170
|
# @return [AttributeIp]
|
@@ -1160,17 +1209,19 @@ module Appwrite
|
|
1160
1209
|
)
|
1161
1210
|
end
|
1162
1211
|
|
1163
|
-
|
1212
|
+
#
|
1213
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateIpColumn` instead.
|
1214
|
+
#
|
1164
1215
|
# Update an ip attribute. Changing the `default` value will not update
|
1165
1216
|
# already existing documents.
|
1166
1217
|
#
|
1167
1218
|
#
|
1168
1219
|
# @param [String] database_id Database ID.
|
1169
|
-
# @param [String] collection_id Collection ID.
|
1220
|
+
# @param [String] collection_id Collection ID.
|
1170
1221
|
# @param [String] key Attribute Key.
|
1171
1222
|
# @param [] required Is attribute required?
|
1172
|
-
# @param [String] default Default value
|
1173
|
-
# @param [String] new_key New
|
1223
|
+
# @param [String] default Default value. Cannot be set when attribute is required.
|
1224
|
+
# @param [String] new_key New Attribute Key.
|
1174
1225
|
#
|
1175
1226
|
# @return [AttributeIp]
|
1176
1227
|
def update_ip_attribute(database_id:, collection_id:, key:, required:, default:, new_key: nil)
|
@@ -1218,14 +1269,337 @@ module Appwrite
|
|
1218
1269
|
)
|
1219
1270
|
end
|
1220
1271
|
|
1221
|
-
|
1272
|
+
#
|
1273
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createLineColumn` instead.
|
1274
|
+
#
|
1275
|
+
# Create a geometric line attribute.
|
1276
|
+
#
|
1277
|
+
# @param [String] database_id Database ID.
|
1278
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
1279
|
+
# @param [String] key Attribute Key.
|
1280
|
+
# @param [] required Is attribute required?
|
1281
|
+
# @param [Array] default Default value for attribute when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when attribute is required.
|
1282
|
+
#
|
1283
|
+
# @return [AttributeLine]
|
1284
|
+
def create_line_attribute(database_id:, collection_id:, key:, required:, default: nil)
|
1285
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/line'
|
1286
|
+
.gsub('{databaseId}', database_id)
|
1287
|
+
.gsub('{collectionId}', collection_id)
|
1288
|
+
|
1289
|
+
if database_id.nil?
|
1290
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1291
|
+
end
|
1292
|
+
|
1293
|
+
if collection_id.nil?
|
1294
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1295
|
+
end
|
1296
|
+
|
1297
|
+
if key.nil?
|
1298
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1299
|
+
end
|
1300
|
+
|
1301
|
+
if required.nil?
|
1302
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1303
|
+
end
|
1304
|
+
|
1305
|
+
api_params = {
|
1306
|
+
key: key,
|
1307
|
+
required: required,
|
1308
|
+
default: default,
|
1309
|
+
}
|
1310
|
+
|
1311
|
+
api_headers = {
|
1312
|
+
"content-type": 'application/json',
|
1313
|
+
}
|
1314
|
+
|
1315
|
+
@client.call(
|
1316
|
+
method: 'POST',
|
1317
|
+
path: api_path,
|
1318
|
+
headers: api_headers,
|
1319
|
+
params: api_params,
|
1320
|
+
response_type: Models::AttributeLine
|
1321
|
+
)
|
1322
|
+
end
|
1323
|
+
|
1324
|
+
#
|
1325
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateLineColumn` instead.
|
1326
|
+
#
|
1327
|
+
# Update a line attribute. Changing the `default` value will not update
|
1328
|
+
# already existing documents.
|
1329
|
+
#
|
1330
|
+
# @param [String] database_id Database ID.
|
1331
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).
|
1332
|
+
# @param [String] key Attribute Key.
|
1333
|
+
# @param [] required Is attribute required?
|
1334
|
+
# @param [Array] default Default value for attribute when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when attribute is required.
|
1335
|
+
# @param [String] new_key New attribute key.
|
1336
|
+
#
|
1337
|
+
# @return [AttributeLine]
|
1338
|
+
def update_line_attribute(database_id:, collection_id:, key:, required:, default: nil, new_key: nil)
|
1339
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/line/{key}'
|
1340
|
+
.gsub('{databaseId}', database_id)
|
1341
|
+
.gsub('{collectionId}', collection_id)
|
1342
|
+
.gsub('{key}', key)
|
1343
|
+
|
1344
|
+
if database_id.nil?
|
1345
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1346
|
+
end
|
1347
|
+
|
1348
|
+
if collection_id.nil?
|
1349
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1350
|
+
end
|
1351
|
+
|
1352
|
+
if key.nil?
|
1353
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1354
|
+
end
|
1355
|
+
|
1356
|
+
if required.nil?
|
1357
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1358
|
+
end
|
1359
|
+
|
1360
|
+
api_params = {
|
1361
|
+
required: required,
|
1362
|
+
default: default,
|
1363
|
+
newKey: new_key,
|
1364
|
+
}
|
1365
|
+
|
1366
|
+
api_headers = {
|
1367
|
+
"content-type": 'application/json',
|
1368
|
+
}
|
1369
|
+
|
1370
|
+
@client.call(
|
1371
|
+
method: 'PATCH',
|
1372
|
+
path: api_path,
|
1373
|
+
headers: api_headers,
|
1374
|
+
params: api_params,
|
1375
|
+
response_type: Models::AttributeLine
|
1376
|
+
)
|
1377
|
+
end
|
1378
|
+
|
1379
|
+
#
|
1380
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createPointColumn` instead.
|
1381
|
+
#
|
1382
|
+
# Create a geometric point attribute.
|
1383
|
+
#
|
1384
|
+
# @param [String] database_id Database ID.
|
1385
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
1386
|
+
# @param [String] key Attribute Key.
|
1387
|
+
# @param [] required Is attribute required?
|
1388
|
+
# @param [Array] default Default value for attribute when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when attribute is required.
|
1389
|
+
#
|
1390
|
+
# @return [AttributePoint]
|
1391
|
+
def create_point_attribute(database_id:, collection_id:, key:, required:, default: nil)
|
1392
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/point'
|
1393
|
+
.gsub('{databaseId}', database_id)
|
1394
|
+
.gsub('{collectionId}', collection_id)
|
1395
|
+
|
1396
|
+
if database_id.nil?
|
1397
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1398
|
+
end
|
1399
|
+
|
1400
|
+
if collection_id.nil?
|
1401
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1402
|
+
end
|
1403
|
+
|
1404
|
+
if key.nil?
|
1405
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1406
|
+
end
|
1407
|
+
|
1408
|
+
if required.nil?
|
1409
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1410
|
+
end
|
1411
|
+
|
1412
|
+
api_params = {
|
1413
|
+
key: key,
|
1414
|
+
required: required,
|
1415
|
+
default: default,
|
1416
|
+
}
|
1417
|
+
|
1418
|
+
api_headers = {
|
1419
|
+
"content-type": 'application/json',
|
1420
|
+
}
|
1421
|
+
|
1422
|
+
@client.call(
|
1423
|
+
method: 'POST',
|
1424
|
+
path: api_path,
|
1425
|
+
headers: api_headers,
|
1426
|
+
params: api_params,
|
1427
|
+
response_type: Models::AttributePoint
|
1428
|
+
)
|
1429
|
+
end
|
1430
|
+
|
1431
|
+
#
|
1432
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updatePointColumn` instead.
|
1433
|
+
#
|
1434
|
+
# Update a point attribute. Changing the `default` value will not update
|
1435
|
+
# already existing documents.
|
1436
|
+
#
|
1437
|
+
# @param [String] database_id Database ID.
|
1438
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).
|
1439
|
+
# @param [String] key Attribute Key.
|
1440
|
+
# @param [] required Is attribute required?
|
1441
|
+
# @param [Array] default Default value for attribute when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when attribute is required.
|
1442
|
+
# @param [String] new_key New attribute key.
|
1443
|
+
#
|
1444
|
+
# @return [AttributePoint]
|
1445
|
+
def update_point_attribute(database_id:, collection_id:, key:, required:, default: nil, new_key: nil)
|
1446
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/point/{key}'
|
1447
|
+
.gsub('{databaseId}', database_id)
|
1448
|
+
.gsub('{collectionId}', collection_id)
|
1449
|
+
.gsub('{key}', key)
|
1450
|
+
|
1451
|
+
if database_id.nil?
|
1452
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1453
|
+
end
|
1454
|
+
|
1455
|
+
if collection_id.nil?
|
1456
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1457
|
+
end
|
1458
|
+
|
1459
|
+
if key.nil?
|
1460
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1461
|
+
end
|
1462
|
+
|
1463
|
+
if required.nil?
|
1464
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1465
|
+
end
|
1466
|
+
|
1467
|
+
api_params = {
|
1468
|
+
required: required,
|
1469
|
+
default: default,
|
1470
|
+
newKey: new_key,
|
1471
|
+
}
|
1472
|
+
|
1473
|
+
api_headers = {
|
1474
|
+
"content-type": 'application/json',
|
1475
|
+
}
|
1476
|
+
|
1477
|
+
@client.call(
|
1478
|
+
method: 'PATCH',
|
1479
|
+
path: api_path,
|
1480
|
+
headers: api_headers,
|
1481
|
+
params: api_params,
|
1482
|
+
response_type: Models::AttributePoint
|
1483
|
+
)
|
1484
|
+
end
|
1485
|
+
|
1486
|
+
#
|
1487
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createPolygonColumn` instead.
|
1488
|
+
#
|
1489
|
+
# Create a geometric polygon attribute.
|
1490
|
+
#
|
1491
|
+
# @param [String] database_id Database ID.
|
1492
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
1493
|
+
# @param [String] key Attribute Key.
|
1494
|
+
# @param [] required Is attribute required?
|
1495
|
+
# @param [Array] default Default value for attribute when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when attribute is required.
|
1496
|
+
#
|
1497
|
+
# @return [AttributePolygon]
|
1498
|
+
def create_polygon_attribute(database_id:, collection_id:, key:, required:, default: nil)
|
1499
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/polygon'
|
1500
|
+
.gsub('{databaseId}', database_id)
|
1501
|
+
.gsub('{collectionId}', collection_id)
|
1502
|
+
|
1503
|
+
if database_id.nil?
|
1504
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1505
|
+
end
|
1506
|
+
|
1507
|
+
if collection_id.nil?
|
1508
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1509
|
+
end
|
1510
|
+
|
1511
|
+
if key.nil?
|
1512
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1513
|
+
end
|
1514
|
+
|
1515
|
+
if required.nil?
|
1516
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1517
|
+
end
|
1518
|
+
|
1519
|
+
api_params = {
|
1520
|
+
key: key,
|
1521
|
+
required: required,
|
1522
|
+
default: default,
|
1523
|
+
}
|
1524
|
+
|
1525
|
+
api_headers = {
|
1526
|
+
"content-type": 'application/json',
|
1527
|
+
}
|
1528
|
+
|
1529
|
+
@client.call(
|
1530
|
+
method: 'POST',
|
1531
|
+
path: api_path,
|
1532
|
+
headers: api_headers,
|
1533
|
+
params: api_params,
|
1534
|
+
response_type: Models::AttributePolygon
|
1535
|
+
)
|
1536
|
+
end
|
1537
|
+
|
1538
|
+
#
|
1539
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updatePolygonColumn` instead.
|
1540
|
+
#
|
1541
|
+
# Update a polygon attribute. Changing the `default` value will not update
|
1542
|
+
# already existing documents.
|
1543
|
+
#
|
1544
|
+
# @param [String] database_id Database ID.
|
1545
|
+
# @param [String] collection_id Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).
|
1546
|
+
# @param [String] key Attribute Key.
|
1547
|
+
# @param [] required Is attribute required?
|
1548
|
+
# @param [Array] default Default value for attribute when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when attribute is required.
|
1549
|
+
# @param [String] new_key New attribute key.
|
1550
|
+
#
|
1551
|
+
# @return [AttributePolygon]
|
1552
|
+
def update_polygon_attribute(database_id:, collection_id:, key:, required:, default: nil, new_key: nil)
|
1553
|
+
api_path = '/databases/{databaseId}/collections/{collectionId}/attributes/polygon/{key}'
|
1554
|
+
.gsub('{databaseId}', database_id)
|
1555
|
+
.gsub('{collectionId}', collection_id)
|
1556
|
+
.gsub('{key}', key)
|
1557
|
+
|
1558
|
+
if database_id.nil?
|
1559
|
+
raise Appwrite::Exception.new('Missing required parameter: "databaseId"')
|
1560
|
+
end
|
1561
|
+
|
1562
|
+
if collection_id.nil?
|
1563
|
+
raise Appwrite::Exception.new('Missing required parameter: "collectionId"')
|
1564
|
+
end
|
1565
|
+
|
1566
|
+
if key.nil?
|
1567
|
+
raise Appwrite::Exception.new('Missing required parameter: "key"')
|
1568
|
+
end
|
1569
|
+
|
1570
|
+
if required.nil?
|
1571
|
+
raise Appwrite::Exception.new('Missing required parameter: "required"')
|
1572
|
+
end
|
1573
|
+
|
1574
|
+
api_params = {
|
1575
|
+
required: required,
|
1576
|
+
default: default,
|
1577
|
+
newKey: new_key,
|
1578
|
+
}
|
1579
|
+
|
1580
|
+
api_headers = {
|
1581
|
+
"content-type": 'application/json',
|
1582
|
+
}
|
1583
|
+
|
1584
|
+
@client.call(
|
1585
|
+
method: 'PATCH',
|
1586
|
+
path: api_path,
|
1587
|
+
headers: api_headers,
|
1588
|
+
params: api_params,
|
1589
|
+
response_type: Models::AttributePolygon
|
1590
|
+
)
|
1591
|
+
end
|
1592
|
+
|
1593
|
+
#
|
1594
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createRelationshipColumn` instead.
|
1595
|
+
#
|
1222
1596
|
# Create relationship attribute. [Learn more about relationship
|
1223
1597
|
# attributes](https://appwrite.io/docs/databases-relationships#relationship-attributes).
|
1224
1598
|
#
|
1225
1599
|
#
|
1226
1600
|
# @param [String] database_id Database ID.
|
1227
|
-
# @param [String] collection_id Collection ID.
|
1228
|
-
# @param [String] related_collection_id Related Collection ID.
|
1601
|
+
# @param [String] collection_id Collection ID.
|
1602
|
+
# @param [String] related_collection_id Related Collection ID.
|
1229
1603
|
# @param [RelationshipType] type Relation type
|
1230
1604
|
# @param [] two_way Is Two Way?
|
1231
1605
|
# @param [String] key Attribute Key.
|
@@ -1276,12 +1650,14 @@ module Appwrite
|
|
1276
1650
|
)
|
1277
1651
|
end
|
1278
1652
|
|
1279
|
-
|
1653
|
+
#
|
1654
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createStringColumn` instead.
|
1655
|
+
#
|
1280
1656
|
# Create a string attribute.
|
1281
1657
|
#
|
1282
1658
|
#
|
1283
1659
|
# @param [String] database_id Database ID.
|
1284
|
-
# @param [String] collection_id Collection ID. You can create a new
|
1660
|
+
# @param [String] collection_id Collection ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
1285
1661
|
# @param [String] key Attribute Key.
|
1286
1662
|
# @param [Integer] size Attribute size for text attributes, in number of characters.
|
1287
1663
|
# @param [] required Is attribute required?
|
@@ -1337,18 +1713,20 @@ module Appwrite
|
|
1337
1713
|
)
|
1338
1714
|
end
|
1339
1715
|
|
1340
|
-
|
1716
|
+
#
|
1717
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateStringColumn` instead.
|
1718
|
+
#
|
1341
1719
|
# Update a string attribute. Changing the `default` value will not update
|
1342
1720
|
# already existing documents.
|
1343
1721
|
#
|
1344
1722
|
#
|
1345
1723
|
# @param [String] database_id Database ID.
|
1346
|
-
# @param [String] collection_id Collection ID. You can create a new
|
1724
|
+
# @param [String] collection_id Collection ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
1347
1725
|
# @param [String] key Attribute Key.
|
1348
1726
|
# @param [] required Is attribute required?
|
1349
1727
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
1350
1728
|
# @param [Integer] size Maximum size of the string attribute.
|
1351
|
-
# @param [String] new_key New
|
1729
|
+
# @param [String] new_key New Attribute Key.
|
1352
1730
|
#
|
1353
1731
|
# @return [AttributeString]
|
1354
1732
|
def update_string_attribute(database_id:, collection_id:, key:, required:, default:, size: nil, new_key: nil)
|
@@ -1397,12 +1775,14 @@ module Appwrite
|
|
1397
1775
|
)
|
1398
1776
|
end
|
1399
1777
|
|
1400
|
-
|
1778
|
+
#
|
1779
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createUrlColumn` instead.
|
1780
|
+
#
|
1401
1781
|
# Create a URL attribute.
|
1402
1782
|
#
|
1403
1783
|
#
|
1404
1784
|
# @param [String] database_id Database ID.
|
1405
|
-
# @param [String] collection_id Collection ID.
|
1785
|
+
# @param [String] collection_id Collection ID.
|
1406
1786
|
# @param [String] key Attribute Key.
|
1407
1787
|
# @param [] required Is attribute required?
|
1408
1788
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
@@ -1450,17 +1830,19 @@ module Appwrite
|
|
1450
1830
|
)
|
1451
1831
|
end
|
1452
1832
|
|
1453
|
-
|
1833
|
+
#
|
1834
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateUrlColumn` instead.
|
1835
|
+
#
|
1454
1836
|
# Update an url attribute. Changing the `default` value will not update
|
1455
1837
|
# already existing documents.
|
1456
1838
|
#
|
1457
1839
|
#
|
1458
1840
|
# @param [String] database_id Database ID.
|
1459
|
-
# @param [String] collection_id Collection ID.
|
1841
|
+
# @param [String] collection_id Collection ID.
|
1460
1842
|
# @param [String] key Attribute Key.
|
1461
1843
|
# @param [] required Is attribute required?
|
1462
1844
|
# @param [String] default Default value for attribute when not provided. Cannot be set when attribute is required.
|
1463
|
-
# @param [String] new_key New
|
1845
|
+
# @param [String] new_key New Attribute Key.
|
1464
1846
|
#
|
1465
1847
|
# @return [AttributeUrl]
|
1466
1848
|
def update_url_attribute(database_id:, collection_id:, key:, required:, default:, new_key: nil)
|
@@ -1508,11 +1890,13 @@ module Appwrite
|
|
1508
1890
|
)
|
1509
1891
|
end
|
1510
1892
|
|
1511
|
-
|
1893
|
+
#
|
1894
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.getColumn` instead.
|
1895
|
+
#
|
1512
1896
|
# Get attribute by ID.
|
1513
1897
|
#
|
1514
1898
|
# @param [String] database_id Database ID.
|
1515
|
-
# @param [String] collection_id Collection ID.
|
1899
|
+
# @param [String] collection_id Collection ID.
|
1516
1900
|
# @param [String] key Attribute Key.
|
1517
1901
|
#
|
1518
1902
|
# @return []
|
@@ -1548,11 +1932,13 @@ module Appwrite
|
|
1548
1932
|
)
|
1549
1933
|
end
|
1550
1934
|
|
1551
|
-
|
1935
|
+
#
|
1936
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.deleteColumn` instead.
|
1937
|
+
#
|
1552
1938
|
# Deletes an attribute.
|
1553
1939
|
#
|
1554
1940
|
# @param [String] database_id Database ID.
|
1555
|
-
# @param [String] collection_id Collection ID.
|
1941
|
+
# @param [String] collection_id Collection ID.
|
1556
1942
|
# @param [String] key Attribute Key.
|
1557
1943
|
#
|
1558
1944
|
# @return []
|
@@ -1589,16 +1975,18 @@ module Appwrite
|
|
1589
1975
|
)
|
1590
1976
|
end
|
1591
1977
|
|
1592
|
-
|
1978
|
+
#
|
1979
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateRelationshipColumn` instead.
|
1980
|
+
#
|
1593
1981
|
# Update relationship attribute. [Learn more about relationship
|
1594
1982
|
# attributes](https://appwrite.io/docs/databases-relationships#relationship-attributes).
|
1595
1983
|
#
|
1596
1984
|
#
|
1597
1985
|
# @param [String] database_id Database ID.
|
1598
|
-
# @param [String] collection_id Collection ID.
|
1986
|
+
# @param [String] collection_id Collection ID.
|
1599
1987
|
# @param [String] key Attribute Key.
|
1600
1988
|
# @param [RelationMutate] on_delete Constraints option
|
1601
|
-
# @param [String] new_key New
|
1989
|
+
# @param [String] new_key New Attribute Key.
|
1602
1990
|
#
|
1603
1991
|
# @return [AttributeRelationship]
|
1604
1992
|
def update_relationship_attribute(database_id:, collection_id:, key:, on_delete: nil, new_key: nil)
|
@@ -1637,7 +2025,9 @@ module Appwrite
|
|
1637
2025
|
)
|
1638
2026
|
end
|
1639
2027
|
|
1640
|
-
|
2028
|
+
#
|
2029
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.listRows` instead.
|
2030
|
+
#
|
1641
2031
|
# Get a list of all the user's documents in a given collection. You can use
|
1642
2032
|
# the query params to filter your results.
|
1643
2033
|
#
|
@@ -1675,7 +2065,9 @@ module Appwrite
|
|
1675
2065
|
)
|
1676
2066
|
end
|
1677
2067
|
|
1678
|
-
|
2068
|
+
#
|
2069
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createRow` instead.
|
2070
|
+
#
|
1679
2071
|
# Create a new Document. Before using this route, you should create a new
|
1680
2072
|
# collection resource using either a [server
|
1681
2073
|
# integration](https://appwrite.io/docs/server/databases#databasesCreateCollection)
|
@@ -1728,11 +2120,9 @@ module Appwrite
|
|
1728
2120
|
)
|
1729
2121
|
end
|
1730
2122
|
|
1731
|
-
|
1732
|
-
#
|
1733
|
-
#
|
1734
|
-
# in future versions.
|
1735
|
-
#
|
2123
|
+
#
|
2124
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createRows` instead.
|
2125
|
+
#
|
1736
2126
|
# Create new Documents. Before using this route, you should create a new
|
1737
2127
|
# collection resource using either a [server
|
1738
2128
|
# integration](https://appwrite.io/docs/server/databases#databasesCreateCollection)
|
@@ -1777,11 +2167,9 @@ module Appwrite
|
|
1777
2167
|
)
|
1778
2168
|
end
|
1779
2169
|
|
1780
|
-
|
1781
|
-
#
|
1782
|
-
#
|
1783
|
-
# in future versions.
|
1784
|
-
#
|
2170
|
+
#
|
2171
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.upsertRows` instead.
|
2172
|
+
#
|
1785
2173
|
# Create or update Documents. Before using this route, you should create a
|
1786
2174
|
# new collection resource using either a [server
|
1787
2175
|
# integration](https://appwrite.io/docs/server/databases#databasesCreateCollection)
|
@@ -1827,11 +2215,9 @@ module Appwrite
|
|
1827
2215
|
)
|
1828
2216
|
end
|
1829
2217
|
|
1830
|
-
|
1831
|
-
#
|
1832
|
-
#
|
1833
|
-
# in future versions.
|
1834
|
-
#
|
2218
|
+
#
|
2219
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateRows` instead.
|
2220
|
+
#
|
1835
2221
|
# Update all documents that match your queries, if no queries are submitted
|
1836
2222
|
# then all documents are updated. You can pass only specific fields to be
|
1837
2223
|
# updated.
|
@@ -1873,11 +2259,9 @@ module Appwrite
|
|
1873
2259
|
)
|
1874
2260
|
end
|
1875
2261
|
|
1876
|
-
|
1877
|
-
#
|
1878
|
-
#
|
1879
|
-
# in future versions.
|
1880
|
-
#
|
2262
|
+
#
|
2263
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.deleteRows` instead.
|
2264
|
+
#
|
1881
2265
|
# Bulk delete documents using queries, if no queries are passed then all
|
1882
2266
|
# documents are deleted.
|
1883
2267
|
#
|
@@ -1916,7 +2300,9 @@ module Appwrite
|
|
1916
2300
|
)
|
1917
2301
|
end
|
1918
2302
|
|
1919
|
-
|
2303
|
+
#
|
2304
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.getRow` instead.
|
2305
|
+
#
|
1920
2306
|
# Get a document by its unique ID. This endpoint response returns a JSON
|
1921
2307
|
# object with the document data.
|
1922
2308
|
#
|
@@ -1960,11 +2346,9 @@ module Appwrite
|
|
1960
2346
|
)
|
1961
2347
|
end
|
1962
2348
|
|
1963
|
-
|
1964
|
-
#
|
1965
|
-
#
|
1966
|
-
# in future versions.
|
1967
|
-
#
|
2349
|
+
#
|
2350
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.upsertRow` instead.
|
2351
|
+
#
|
1968
2352
|
# Create or update a Document. Before using this route, you should create a
|
1969
2353
|
# new collection resource using either a [server
|
1970
2354
|
# integration](https://appwrite.io/docs/server/databases#databasesCreateCollection)
|
@@ -2017,7 +2401,9 @@ module Appwrite
|
|
2017
2401
|
)
|
2018
2402
|
end
|
2019
2403
|
|
2020
|
-
|
2404
|
+
#
|
2405
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.updateRow` instead.
|
2406
|
+
#
|
2021
2407
|
# Update a document by its unique ID. Using the patch method you can pass
|
2022
2408
|
# only specific fields that will get updated.
|
2023
2409
|
#
|
@@ -2064,7 +2450,9 @@ module Appwrite
|
|
2064
2450
|
)
|
2065
2451
|
end
|
2066
2452
|
|
2067
|
-
|
2453
|
+
#
|
2454
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.deleteRow` instead.
|
2455
|
+
#
|
2068
2456
|
# Delete a document by its unique ID.
|
2069
2457
|
#
|
2070
2458
|
# @param [String] database_id Database ID.
|
@@ -2105,14 +2493,16 @@ module Appwrite
|
|
2105
2493
|
)
|
2106
2494
|
end
|
2107
2495
|
|
2108
|
-
|
2496
|
+
#
|
2497
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.decrementRowColumn` instead.
|
2498
|
+
#
|
2109
2499
|
# Decrement a specific attribute of a document by a given value.
|
2110
2500
|
#
|
2111
2501
|
# @param [String] database_id Database ID.
|
2112
2502
|
# @param [String] collection_id Collection ID.
|
2113
2503
|
# @param [String] document_id Document ID.
|
2114
2504
|
# @param [String] attribute Attribute key.
|
2115
|
-
# @param [Float] value Value to
|
2505
|
+
# @param [Float] value Value to increment the attribute by. The value must be a number.
|
2116
2506
|
# @param [Float] min Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.
|
2117
2507
|
#
|
2118
2508
|
# @return [Document]
|
@@ -2157,7 +2547,9 @@ module Appwrite
|
|
2157
2547
|
)
|
2158
2548
|
end
|
2159
2549
|
|
2160
|
-
|
2550
|
+
#
|
2551
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.incrementRowColumn` instead.
|
2552
|
+
#
|
2161
2553
|
# Increment a specific attribute of a document by a given value.
|
2162
2554
|
#
|
2163
2555
|
# @param [String] database_id Database ID.
|
@@ -2209,7 +2601,9 @@ module Appwrite
|
|
2209
2601
|
)
|
2210
2602
|
end
|
2211
2603
|
|
2212
|
-
|
2604
|
+
#
|
2605
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.listIndexes` instead.
|
2606
|
+
#
|
2213
2607
|
# List indexes in the collection.
|
2214
2608
|
#
|
2215
2609
|
# @param [String] database_id Database ID.
|
@@ -2246,7 +2640,9 @@ module Appwrite
|
|
2246
2640
|
)
|
2247
2641
|
end
|
2248
2642
|
|
2249
|
-
|
2643
|
+
#
|
2644
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.createIndex` instead.
|
2645
|
+
#
|
2250
2646
|
# Creates an index on the attributes listed. Your index should include all
|
2251
2647
|
# the attributes you will query in a single request.
|
2252
2648
|
# Attributes can be `key`, `fulltext`, and `unique`.
|
@@ -2306,7 +2702,9 @@ module Appwrite
|
|
2306
2702
|
)
|
2307
2703
|
end
|
2308
2704
|
|
2309
|
-
|
2705
|
+
#
|
2706
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.getIndex` instead.
|
2707
|
+
#
|
2310
2708
|
# Get index by ID.
|
2311
2709
|
#
|
2312
2710
|
# @param [String] database_id Database ID.
|
@@ -2347,7 +2745,9 @@ module Appwrite
|
|
2347
2745
|
)
|
2348
2746
|
end
|
2349
2747
|
|
2350
|
-
|
2748
|
+
#
|
2749
|
+
# @deprecated This API has been deprecated since 1.8.0. Please use `TablesDB.deleteIndex` instead.
|
2750
|
+
#
|
2351
2751
|
# Delete an index.
|
2352
2752
|
#
|
2353
2753
|
# @param [String] database_id Database ID.
|
@@ -2388,6 +2788,5 @@ module Appwrite
|
|
2388
2788
|
)
|
2389
2789
|
end
|
2390
2790
|
|
2391
|
-
|
2392
2791
|
end
|
2393
2792
|
end
|