@@ -1758,6 +1758,7 @@ def insert_many(
17581758 keep_none : Optional [bool ] = None ,
17591759 merge : Optional [bool ] = None ,
17601760 refill_index_caches : Optional [bool ] = None ,
1761+ version_attribute : Optional [str ] = None ,
17611762 ) -> Result [Union [bool , List [Union [Json , ArangoServerError ]]]]:
17621763 """Insert multiple documents.
17631764
@@ -1812,6 +1813,9 @@ def insert_many(
18121813 index caches if document insertions affect the edge index or
18131814 cache-enabled persistent indexes.
18141815 :type refill_index_caches: bool | None
1816+ param version_attribute: support for simple external versioning to
1817+ document operations.
1818+ :type version_attribute: str
18151819 :return: List of document metadata (e.g. document keys, revisions) and
18161820 any exception, or True if parameter **silent** was set to True.
18171821 :rtype: [dict | ArangoServerError] | bool
@@ -1834,6 +1838,8 @@ def insert_many(
18341838 params ["keepNull" ] = keep_none
18351839 if merge is not None :
18361840 params ["mergeObjects" ] = merge
1841+ if version_attribute is not None :
1842+ params ["versionAttribute" ] = version_attribute
18371843
18381844 # New in ArangoDB 3.9.6 and 3.10.2
18391845 if refill_index_caches is not None :
@@ -1880,6 +1886,7 @@ def update_many(
18801886 silent : bool = False ,
18811887 refill_index_caches : Optional [bool ] = None ,
18821888 raise_on_document_error : bool = False ,
1889+ version_attribute : Optional [str ] = None ,
18831890 ) -> Result [Union [bool , List [Union [Json , ArangoServerError ]]]]:
18841891 """Update multiple documents.
18851892
@@ -1932,6 +1939,9 @@ def update_many(
19321939 as opposed to returning the error as an object in the result list.
19331940 Defaults to False.
19341941 :type raise_on_document_error: bool
1942+ param version_attribute: support for simple external versioning to
1943+ document operations.
1944+ :type version_attribute: str
19351945 :return: List of document metadata (e.g. document keys, revisions) and
19361946 any exceptions, or True if parameter **silent** was set to True.
19371947 :rtype: [dict | ArangoError] | bool
@@ -1948,6 +1958,8 @@ def update_many(
19481958 }
19491959 if sync is not None :
19501960 params ["waitForSync" ] = sync
1961+ if version_attribute is not None :
1962+ params ["versionAttribute" ] = version_attribute
19511963
19521964 # New in ArangoDB 3.9.6 and 3.10.2
19531965 if refill_index_caches is not None :
@@ -2084,6 +2096,7 @@ def replace_many(
20842096 sync : Optional [bool ] = None ,
20852097 silent : bool = False ,
20862098 refill_index_caches : Optional [bool ] = None ,
2099+ version_attribute : Optional [str ] = None ,
20872100 ) -> Result [Union [bool , List [Union [Json , ArangoServerError ]]]]:
20882101 """Replace multiple documents.
20892102
@@ -2125,6 +2138,9 @@ def replace_many(
21252138 index caches if document operations affect the edge index or
21262139 cache-enabled persistent indexes.
21272140 :type refill_index_caches: bool | None
2141+ param version_attribute: support for simple external versioning to
2142+ document operations.
2143+ :type version_attribute: str
21282144 :return: List of document metadata (e.g. document keys, revisions) and
21292145 any exceptions, or True if parameter **silent** was set to True.
21302146 :rtype: [dict | ArangoServerError] | bool
@@ -2139,6 +2155,8 @@ def replace_many(
21392155 }
21402156 if sync is not None :
21412157 params ["waitForSync" ] = sync
2158+ if version_attribute is not None :
2159+ params ["versionAttribute" ] = version_attribute
21422160
21432161 # New in ArangoDB 3.9.6 and 3.10.2
21442162 if refill_index_caches is not None :
@@ -2613,6 +2631,7 @@ def insert(
26132631 keep_none : Optional [bool ] = None ,
26142632 merge : Optional [bool ] = None ,
26152633 refill_index_caches : Optional [bool ] = None ,
2634+ version_attribute : Optional [str ] = None ,
26162635 ) -> Result [Union [bool , Json ]]:
26172636 """Insert a new document.
26182637
@@ -2651,6 +2670,9 @@ def insert(
26512670 index caches if document insertions affect the edge index or
26522671 cache-enabled persistent indexes.
26532672 :type refill_index_caches: bool | None
2673+ param version_attribute: support for simple external versioning to
2674+ document operations.
2675+ :type version_attribute: str
26542676 :return: Document metadata (e.g. document key, revision) or True if
26552677 parameter **silent** was set to True.
26562678 :rtype: bool | dict
@@ -2672,6 +2694,8 @@ def insert(
26722694 params ["keepNull" ] = keep_none
26732695 if merge is not None :
26742696 params ["mergeObjects" ] = merge
2697+ if version_attribute is not None :
2698+ params ["versionAttribute" ] = version_attribute
26752699
26762700 # New in ArangoDB 3.9.6 and 3.10.2
26772701 if refill_index_caches is not None :
@@ -2710,6 +2734,7 @@ def update(
27102734 sync : Optional [bool ] = None ,
27112735 silent : bool = False ,
27122736 refill_index_caches : Optional [bool ] = None ,
2737+ version_attribute : Optional [str ] = None ,
27132738 ) -> Result [Union [bool , Json ]]:
27142739 """Update a document.
27152740
@@ -2740,6 +2765,9 @@ def update(
27402765 index caches if document insertions affect the edge index or
27412766 cache-enabled persistent indexes.
27422767 :type refill_index_caches: bool | None
2768+ param version_attribute: support for simple external versioning
2769+ to document operations.
2770+ :type version_attribute: str
27432771 :return: Document metadata (e.g. document key, revision) or True if
27442772 parameter **silent** was set to True.
27452773 :rtype: bool | dict
@@ -2758,6 +2786,9 @@ def update(
27582786 if sync is not None :
27592787 params ["waitForSync" ] = sync
27602788
2789+ if version_attribute is not None :
2790+ params ["versionAttribute" ] = version_attribute
2791+
27612792 # New in ArangoDB 3.9.6 and 3.10.2
27622793 if refill_index_caches is not None :
27632794 params ["refillIndexCaches" ] = refill_index_caches
@@ -2793,6 +2824,7 @@ def replace(
27932824 sync : Optional [bool ] = None ,
27942825 silent : bool = False ,
27952826 refill_index_caches : Optional [bool ] = None ,
2827+ version_attribute : Optional [str ] = None ,
27962828 ) -> Result [Union [bool , Json ]]:
27972829 """Replace a document.
27982830
@@ -2818,6 +2850,9 @@ def replace(
28182850 index caches if document insertions affect the edge index or
28192851 cache-enabled persistent indexes.
28202852 :type refill_index_caches: bool | None
2853+ param version_attribute: support for simple external versioning to
2854+ document operations.
2855+ :type version_attribute: str
28212856 :return: Document metadata (e.g. document key, revision) or True if
28222857 parameter **silent** was set to True.
28232858 :rtype: bool | dict
@@ -2834,6 +2869,9 @@ def replace(
28342869 if sync is not None :
28352870 params ["waitForSync" ] = sync
28362871
2872+ if version_attribute is not None :
2873+ params ["versionAttribute" ] = version_attribute
2874+
28372875 # New in ArangoDB 3.9.6 and 3.10.2
28382876 if refill_index_caches is not None :
28392877 params ["refillIndexCaches" ] = refill_index_caches
0 commit comments