@ibm-cloud/cloudant 0.0.16 → 0.0.20

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.
package/cloudant/v1.d.ts CHANGED
@@ -182,17 +182,18 @@ declare class CloudantV1 extends CloudantBaseService {
182
182
  * key order.
183
183
  * @param {string} [params.feed] - Query parameter to specify the changes feed type.
184
184
  * @param {string} [params.filter] - Query parameter to specify a filter function from a design document that will
185
- * filter the changes stream emitting only filtered events. Additionally, several built-in filters are available:
186
- * - `_design`
187
- * - Returns only changes to design documents.
188
- * - `_doc_ids`
189
- * - Returns changes for documents whit an ID matching one specified in `doc_ids` request body parameter.
190
- * - `_selector`
191
- * - Returns changes for documents that match the `selector` request body parameter. The selector syntax is the same
192
- * as used for `_find`.
193
- * - `_view`
194
- * - Returns changes for documents that match an existing map function in the view specified by the query parameter
195
- * `view`.
185
+ * filter the changes stream emitting only filtered events. For example: `design_doc/filtername`.
186
+ *
187
+ * Additionally, some keywords are reserved for built-in filters:
188
+ *
189
+ * * `_design` - Returns only changes to design documents.
190
+ * * `_doc_ids` - Returns changes for documents with an ID matching one specified in
191
+ * `doc_ids` request body parameter.
192
+ * * `_selector` - Returns changes for documents that match the `selector`
193
+ * request body parameter. The selector syntax is the same as used for
194
+ * `_find`.
195
+ * * `_view` - Returns changes for documents that match an existing map
196
+ * function in the view specified by the query parameter `view`.
196
197
  * @param {number} [params.heartbeat] - Query parameter to specify the period in milliseconds after which an empty
197
198
  * line is sent in the results. Only applicable for longpoll, continuous, and eventsource feeds. Overrides any timeout
198
199
  * to keep the feed alive indefinitely. May also be `true` to use default value of 60000.
@@ -266,17 +267,18 @@ declare class CloudantV1 extends CloudantBaseService {
266
267
  * key order.
267
268
  * @param {string} [params.feed] - Query parameter to specify the changes feed type.
268
269
  * @param {string} [params.filter] - Query parameter to specify a filter function from a design document that will
269
- * filter the changes stream emitting only filtered events. Additionally, several built-in filters are available:
270
- * - `_design`
271
- * - Returns only changes to design documents.
272
- * - `_doc_ids`
273
- * - Returns changes for documents whit an ID matching one specified in `doc_ids` request body parameter.
274
- * - `_selector`
275
- * - Returns changes for documents that match the `selector` request body parameter. The selector syntax is the same
276
- * as used for `_find`.
277
- * - `_view`
278
- * - Returns changes for documents that match an existing map function in the view specified by the query parameter
279
- * `view`.
270
+ * filter the changes stream emitting only filtered events. For example: `design_doc/filtername`.
271
+ *
272
+ * Additionally, some keywords are reserved for built-in filters:
273
+ *
274
+ * * `_design` - Returns only changes to design documents.
275
+ * * `_doc_ids` - Returns changes for documents with an ID matching one specified in
276
+ * `doc_ids` request body parameter.
277
+ * * `_selector` - Returns changes for documents that match the `selector`
278
+ * request body parameter. The selector syntax is the same as used for
279
+ * `_find`.
280
+ * * `_view` - Returns changes for documents that match an existing map
281
+ * function in the view specified by the query parameter `view`.
280
282
  * @param {number} [params.heartbeat] - Query parameter to specify the period in milliseconds after which an empty
281
283
  * line is sent in the results. Only applicable for longpoll, continuous, and eventsource feeds. Overrides any timeout
282
284
  * to keep the feed alive indefinitely. May also be `true` to use default value of 60000.
@@ -301,7 +303,7 @@ declare class CloudantV1 extends CloudantBaseService {
301
303
  * @param {string} [params.view] - Query parameter to specify a view function as a filter. Documents pass the filter
302
304
  * if the view's map function emits at least one record for them.
303
305
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
304
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
306
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
305
307
  */
306
308
  postChangesAsStream(params: CloudantV1.PostChangesAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
307
309
  /*************************
@@ -420,7 +422,7 @@ declare class CloudantV1 extends CloudantBaseService {
420
422
  *
421
423
  * @param {Object} params - The parameters to send to the service.
422
424
  * @param {string} params.db - Path parameter to specify the database name.
423
- * @param {Document|NodeJS.ReadableStream|Buffer} params.document - HTTP request body for Document operations.
425
+ * @param {Document | NodeJS.ReadableStream | Buffer} params.document - HTTP request body for Document operations.
424
426
  * @param {string} [params.contentType] - The type of the input.
425
427
  * @param {string} [params.batch] - Query parameter to specify whether to store in batch mode. The server will respond
426
428
  * with a HTTP 202 Accepted response code immediately.
@@ -491,7 +493,7 @@ declare class CloudantV1 extends CloudantBaseService {
491
493
  * @param {string[]} [params.keys] - Schema for a list of document IDs.
492
494
  * @param {string} [params.startkey] - Schema for a document ID.
493
495
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
494
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
496
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
495
497
  */
496
498
  postAllDocsAsStream(params: CloudantV1.PostAllDocsAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
497
499
  /**
@@ -523,7 +525,7 @@ declare class CloudantV1 extends CloudantBaseService {
523
525
  * individual view query to be executed. The field names and their meaning are the same as the query parameters of a
524
526
  * regular `/_all_docs` request.
525
527
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
526
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
528
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
527
529
  */
528
530
  postAllDocsQueriesAsStream(params: CloudantV1.PostAllDocsQueriesAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
529
531
  /**
@@ -535,7 +537,7 @@ declare class CloudantV1 extends CloudantBaseService {
535
537
  *
536
538
  * @param {Object} params - The parameters to send to the service.
537
539
  * @param {string} params.db - Path parameter to specify the database name.
538
- * @param {BulkDocs|NodeJS.ReadableStream|Buffer} params.bulkDocs - HTTP request body for postBulkDocs.
540
+ * @param {BulkDocs | NodeJS.ReadableStream | Buffer} params.bulkDocs - HTTP request body for postBulkDocs.
539
541
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
540
542
  * @returns {Promise<CloudantV1.Response<CloudantV1.DocumentResult[]>>}
541
543
  */
@@ -577,7 +579,7 @@ declare class CloudantV1 extends CloudantBaseService {
577
579
  * @param {boolean} [params.revs] - Query parameter to specify whether to include a list of all known document
578
580
  * revisions.
579
581
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
580
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
582
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
581
583
  */
582
584
  postBulkGetAsMixed(params: CloudantV1.PostBulkGetAsMixedParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
583
585
  /**
@@ -597,7 +599,7 @@ declare class CloudantV1 extends CloudantBaseService {
597
599
  * @param {boolean} [params.revs] - Query parameter to specify whether to include a list of all known document
598
600
  * revisions.
599
601
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
600
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
602
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
601
603
  */
602
604
  postBulkGetAsRelated(params: CloudantV1.PostBulkGetAsRelatedParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
603
605
  /**
@@ -617,7 +619,7 @@ declare class CloudantV1 extends CloudantBaseService {
617
619
  * @param {boolean} [params.revs] - Query parameter to specify whether to include a list of all known document
618
620
  * revisions.
619
621
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
620
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
622
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
621
623
  */
622
624
  postBulkGetAsStream(params: CloudantV1.PostBulkGetAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
623
625
  /**
@@ -704,7 +706,7 @@ declare class CloudantV1 extends CloudantBaseService {
704
706
  * @param {boolean} [params.revsInfo] - Query parameter to specify whether to includes detailed information for all
705
707
  * known document revisions.
706
708
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
707
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
709
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
708
710
  */
709
711
  getDocumentAsMixed(params: CloudantV1.GetDocumentAsMixedParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
710
712
  /**
@@ -738,7 +740,7 @@ declare class CloudantV1 extends CloudantBaseService {
738
740
  * @param {boolean} [params.revsInfo] - Query parameter to specify whether to includes detailed information for all
739
741
  * known document revisions.
740
742
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
741
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
743
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
742
744
  */
743
745
  getDocumentAsRelated(params: CloudantV1.GetDocumentAsRelatedParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
744
746
  /**
@@ -772,7 +774,7 @@ declare class CloudantV1 extends CloudantBaseService {
772
774
  * @param {boolean} [params.revsInfo] - Query parameter to specify whether to includes detailed information for all
773
775
  * known document revisions.
774
776
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
775
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
777
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
776
778
  */
777
779
  getDocumentAsStream(params: CloudantV1.GetDocumentAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
778
780
  /**
@@ -784,7 +786,7 @@ declare class CloudantV1 extends CloudantBaseService {
784
786
  * @param {Object} params - The parameters to send to the service.
785
787
  * @param {string} params.db - Path parameter to specify the database name.
786
788
  * @param {string} params.docId - Path parameter to specify the document ID.
787
- * @param {Document|NodeJS.ReadableStream|Buffer} params.document - HTTP request body for Document operations.
789
+ * @param {Document | NodeJS.ReadableStream | Buffer} params.document - HTTP request body for Document operations.
788
790
  * @param {string} [params.contentType] - The type of the input.
789
791
  * @param {string} [params.ifMatch] - Header parameter to specify the document revision. Alternative to rev query
790
792
  * parameter.
@@ -1057,7 +1059,7 @@ declare class CloudantV1 extends CloudantBaseService {
1057
1059
  * @param {string} [params.update] - Parameter to specify whether or not the view in question should be updated prior
1058
1060
  * to responding to the user.
1059
1061
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1060
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1062
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1061
1063
  */
1062
1064
  postViewAsStream(params: CloudantV1.PostViewAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1063
1065
  /**
@@ -1091,7 +1093,7 @@ declare class CloudantV1 extends CloudantBaseService {
1091
1093
  * view query to be executed. The field names and their meaning are the same as the query parameters of a regular view
1092
1094
  * request.
1093
1095
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1094
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1096
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1095
1097
  */
1096
1098
  postViewQueriesAsStream(params: CloudantV1.PostViewQueriesAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1097
1099
  /*************************
@@ -1174,7 +1176,7 @@ declare class CloudantV1 extends CloudantBaseService {
1174
1176
  * @param {string[]} [params.keys] - Schema for a list of document IDs.
1175
1177
  * @param {string} [params.startkey] - Schema for a document ID.
1176
1178
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1177
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1179
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1178
1180
  */
1179
1181
  postPartitionAllDocsAsStream(params: CloudantV1.PostPartitionAllDocsAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1180
1182
  /**
@@ -1254,7 +1256,7 @@ declare class CloudantV1 extends CloudantBaseService {
1254
1256
  * Fields that are used for sorting must be indexed by the same indexer that is used for the search query.
1255
1257
  * @param {string} [params.stale] - Do not wait for the index to finish building to return results.
1256
1258
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1257
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1259
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1258
1260
  */
1259
1261
  postPartitionSearchAsStream(params: CloudantV1.PostPartitionSearchAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1260
1262
  /**
@@ -1352,7 +1354,7 @@ declare class CloudantV1 extends CloudantBaseService {
1352
1354
  * @param {string} [params.update] - Parameter to specify whether or not the view in question should be updated prior
1353
1355
  * to responding to the user.
1354
1356
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1355
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1357
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1356
1358
  */
1357
1359
  postPartitionViewAsStream(params: CloudantV1.PostPartitionViewAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1358
1360
  /**
@@ -1460,7 +1462,7 @@ declare class CloudantV1 extends CloudantBaseService {
1460
1462
  * @param {string[]} [params.useIndex] - Use this option to identify a specific index for query to run against, rather
1461
1463
  * than by using the IBM Cloudant Query algorithm to find the best index.
1462
1464
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1463
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1465
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1464
1466
  */
1465
1467
  postPartitionFindAsStream(params: CloudantV1.PostPartitionFindAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1466
1468
  /*************************
@@ -1634,7 +1636,7 @@ declare class CloudantV1 extends CloudantBaseService {
1634
1636
  * that many replicas before it is returned in the results. The request will take more time than using only the
1635
1637
  * document that is stored locally with the index.
1636
1638
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1637
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1639
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1638
1640
  */
1639
1641
  postFindAsStream(params: CloudantV1.PostFindAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1640
1642
  /**
@@ -1822,7 +1824,7 @@ declare class CloudantV1 extends CloudantBaseService {
1822
1824
  * objects. The field names of the JSON objects are names for ranges. The values are strings that describe the range,
1823
1825
  * for example "[0 TO 10]". This option is only available when making global queries.
1824
1826
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1825
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1827
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1826
1828
  */
1827
1829
  postSearchAsStream(params: CloudantV1.PostSearchAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1828
1830
  /**
@@ -1937,7 +1939,7 @@ declare class CloudantV1 extends CloudantBaseService {
1937
1939
  * @param {string} [params.stale] - Query parameter to specify to not wait for the index to finish building before
1938
1940
  * returning results.
1939
1941
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
1940
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
1942
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
1941
1943
  */
1942
1944
  getGeoAsStream(params: CloudantV1.GetGeoAsStreamParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
1943
1945
  /**
@@ -2006,17 +2008,6 @@ declare class CloudantV1 extends CloudantBaseService {
2006
2008
  * @returns {Promise<CloudantV1.Response<CloudantV1.Empty>>}
2007
2009
  */
2008
2010
  headSchedulerJob(params: CloudantV1.HeadSchedulerJobParams): Promise<CloudantV1.Response<CloudantV1.Empty>>;
2009
- /**
2010
- * Create or modify a replication operation.
2011
- *
2012
- * Requests, configures, or stops a replicate operation.
2013
- *
2014
- * @param {Object} params - The parameters to send to the service.
2015
- * @param {ReplicationDocument} params.replicationDocument - HTTP request body for replication operations.
2016
- * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
2017
- * @returns {Promise<CloudantV1.Response<CloudantV1.ReplicationResult>>}
2018
- */
2019
- postReplicate(params: CloudantV1.PostReplicateParams): Promise<CloudantV1.Response<CloudantV1.ReplicationResult>>;
2020
2011
  /**
2021
2012
  * Cancel a replication.
2022
2013
  *
@@ -2067,7 +2058,7 @@ declare class CloudantV1 extends CloudantBaseService {
2067
2058
  */
2068
2059
  getReplicationDocument(params: CloudantV1.GetReplicationDocumentParams): Promise<CloudantV1.Response<CloudantV1.ReplicationDocument>>;
2069
2060
  /**
2070
- * Start or update a replication.
2061
+ * Create or modify a replication using a replication document.
2071
2062
  *
2072
2063
  * Creates or modifies a document in the `_replicator` database to start a new replication or to edit an existing
2073
2064
  * replication.
@@ -2312,7 +2303,7 @@ declare class CloudantV1 extends CloudantBaseService {
2312
2303
  * implementation of resumable downloads and skippable streams. This is available for all attachments inside CouchDB.
2313
2304
  * @param {string} [params.rev] - Query parameter to specify a document revision.
2314
2305
  * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
2315
- * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream|Buffer>>}
2306
+ * @returns {Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>}
2316
2307
  */
2317
2308
  getAttachment(params: CloudantV1.GetAttachmentParams): Promise<CloudantV1.Response<NodeJS.ReadableStream | Buffer>>;
2318
2309
  /**
@@ -2330,7 +2321,7 @@ declare class CloudantV1 extends CloudantBaseService {
2330
2321
  * @param {string} params.db - Path parameter to specify the database name.
2331
2322
  * @param {string} params.docId - Path parameter to specify the document ID.
2332
2323
  * @param {string} params.attachmentName - Path parameter to specify the attachment name.
2333
- * @param {NodeJS.ReadableStream|Buffer} params.attachment - HTTP request body for attachment operations.
2324
+ * @param {NodeJS.ReadableStream | Buffer} params.attachment - HTTP request body for attachment operations.
2334
2325
  * @param {string} params.contentType - Content-Type of the attachment.
2335
2326
  * @param {string} [params.ifMatch] - Header parameter to specify the document revision. Alternative to rev query
2336
2327
  * parameter.
@@ -2404,7 +2395,7 @@ declare class CloudantV1 extends CloudantBaseService {
2404
2395
  * @param {Object} params - The parameters to send to the service.
2405
2396
  * @param {string} params.db - Path parameter to specify the database name.
2406
2397
  * @param {string} params.docId - Path parameter to specify the document ID.
2407
- * @param {Document|NodeJS.ReadableStream|Buffer} params.document - HTTP request body for Document operations.
2398
+ * @param {Document | NodeJS.ReadableStream | Buffer} params.document - HTTP request body for Document operations.
2408
2399
  * @param {string} [params.contentType] - The type of the input.
2409
2400
  * @param {string} [params.batch] - Query parameter to specify whether to store in batch mode. The server will respond
2410
2401
  * with a HTTP 202 Accepted response code immediately.
@@ -2415,18 +2406,6 @@ declare class CloudantV1 extends CloudantBaseService {
2415
2406
  /*************************
2416
2407
  * databaseDetails
2417
2408
  ************************/
2418
- /**
2419
- * Query which document revisions are missing from the database.
2420
- *
2421
- * Given a list of document revisions, returns the document revisions that do not exist in the database.
2422
- *
2423
- * @param {Object} params - The parameters to send to the service.
2424
- * @param {string} params.db - Path parameter to specify the database name.
2425
- * @param {JsonObject} params.documentRevisions - HTTP request body for postMissingRevs and postRevsDiff.
2426
- * @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
2427
- * @returns {Promise<CloudantV1.Response<CloudantV1.MissingRevsResult>>}
2428
- */
2429
- postMissingRevs(params: CloudantV1.PostMissingRevsParams): Promise<CloudantV1.Response<CloudantV1.MissingRevsResult>>;
2430
2409
  /**
2431
2410
  * Query the document revisions and possible ancestors missing from the database.
2432
2411
  *
@@ -2670,17 +2649,18 @@ declare namespace CloudantV1 {
2670
2649
  /** Query parameter to specify the changes feed type. */
2671
2650
  feed?: PostChangesConstants.Feed | string;
2672
2651
  /** Query parameter to specify a filter function from a design document that will filter the changes stream
2673
- * emitting only filtered events. Additionally, several built-in filters are available:
2674
- * - `_design`
2675
- * - Returns only changes to design documents.
2676
- * - `_doc_ids`
2677
- * - Returns changes for documents whit an ID matching one specified in `doc_ids` request body parameter.
2678
- * - `_selector`
2679
- * - Returns changes for documents that match the `selector` request body parameter. The selector syntax is the
2680
- * same as used for `_find`.
2681
- * - `_view`
2682
- * - Returns changes for documents that match an existing map function in the view specified by the query parameter
2683
- * `view`.
2652
+ * emitting only filtered events. For example: `design_doc/filtername`.
2653
+ *
2654
+ * Additionally, some keywords are reserved for built-in filters:
2655
+ *
2656
+ * * `_design` - Returns only changes to design documents.
2657
+ * * `_doc_ids` - Returns changes for documents with an ID matching one specified in
2658
+ * `doc_ids` request body parameter.
2659
+ * * `_selector` - Returns changes for documents that match the `selector`
2660
+ * request body parameter. The selector syntax is the same as used for
2661
+ * `_find`.
2662
+ * * `_view` - Returns changes for documents that match an existing map
2663
+ * function in the view specified by the query parameter `view`.
2684
2664
  */
2685
2665
  filter?: string;
2686
2666
  /** Query parameter to specify the period in milliseconds after which an empty line is sent in the results. Only
@@ -2783,17 +2763,18 @@ declare namespace CloudantV1 {
2783
2763
  /** Query parameter to specify the changes feed type. */
2784
2764
  feed?: PostChangesAsStreamConstants.Feed | string;
2785
2765
  /** Query parameter to specify a filter function from a design document that will filter the changes stream
2786
- * emitting only filtered events. Additionally, several built-in filters are available:
2787
- * - `_design`
2788
- * - Returns only changes to design documents.
2789
- * - `_doc_ids`
2790
- * - Returns changes for documents whit an ID matching one specified in `doc_ids` request body parameter.
2791
- * - `_selector`
2792
- * - Returns changes for documents that match the `selector` request body parameter. The selector syntax is the
2793
- * same as used for `_find`.
2794
- * - `_view`
2795
- * - Returns changes for documents that match an existing map function in the view specified by the query parameter
2796
- * `view`.
2766
+ * emitting only filtered events. For example: `design_doc/filtername`.
2767
+ *
2768
+ * Additionally, some keywords are reserved for built-in filters:
2769
+ *
2770
+ * * `_design` - Returns only changes to design documents.
2771
+ * * `_doc_ids` - Returns changes for documents with an ID matching one specified in
2772
+ * `doc_ids` request body parameter.
2773
+ * * `_selector` - Returns changes for documents that match the `selector`
2774
+ * request body parameter. The selector syntax is the same as used for
2775
+ * `_find`.
2776
+ * * `_view` - Returns changes for documents that match an existing map
2777
+ * function in the view specified by the query parameter `view`.
2797
2778
  */
2798
2779
  filter?: string;
2799
2780
  /** Query parameter to specify the period in milliseconds after which an empty line is sent in the results. Only
@@ -4981,12 +4962,6 @@ declare namespace CloudantV1 {
4981
4962
  jobId: string;
4982
4963
  headers?: OutgoingHttpHeaders;
4983
4964
  }
4984
- /** Parameters for the `postReplicate` operation. */
4985
- interface PostReplicateParams {
4986
- /** HTTP request body for replication operations. */
4987
- replicationDocument: ReplicationDocument;
4988
- headers?: OutgoingHttpHeaders;
4989
- }
4990
4965
  /** Parameters for the `deleteReplicationDocument` operation. */
4991
4966
  interface DeleteReplicationDocumentParams {
4992
4967
  /** Path parameter to specify the document ID. */
@@ -5378,14 +5353,6 @@ declare namespace CloudantV1 {
5378
5353
  OK = "ok"
5379
5354
  }
5380
5355
  }
5381
- /** Parameters for the `postMissingRevs` operation. */
5382
- interface PostMissingRevsParams {
5383
- /** Path parameter to specify the database name. */
5384
- db: string;
5385
- /** HTTP request body for postMissingRevs and postRevsDiff. */
5386
- documentRevisions: JsonObject;
5387
- headers?: OutgoingHttpHeaders;
5388
- }
5389
5356
  /** Parameters for the `postRevsDiff` operation. */
5390
5357
  interface PostRevsDiffParams {
5391
5358
  /** Path parameter to specify the database name. */
@@ -5782,6 +5749,8 @@ declare namespace CloudantV1 {
5782
5749
  }
5783
5750
  /** Schema for database information keyed by database name. */
5784
5751
  interface DbsInfoResult {
5752
+ /** The name of the error. */
5753
+ error?: string;
5785
5754
  /** Schema for information about a database. */
5786
5755
  info?: DatabaseInformation;
5787
5756
  /** Database name. */
@@ -5819,10 +5788,33 @@ declare namespace CloudantV1 {
5819
5788
  language?: string;
5820
5789
  /** Schema for design document options. */
5821
5790
  options?: DesignDocumentOptions;
5822
- /** Schema for update function definitions. */
5823
- updates?: JsonObject;
5824
- /** Schema for validate document update functions definition. */
5825
- validate_doc_update?: JsonObject;
5791
+ /** Validate document update function can be used to prevent invalid or unauthorized document update requests
5792
+ * from being stored. Validation functions typically examine the structure of the new document to ensure that
5793
+ * required fields are present and to verify that the requesting user should be allowed to make changes to the
5794
+ * document properties. When a write request is received for a given database, the validation function in each
5795
+ * design document in that database is called in an unspecified order. If any of the validation functions throw an
5796
+ * error, the write will not succeed.
5797
+ *
5798
+ * The validation function can abort the pending document write by throwing one of two error objects:
5799
+ *
5800
+ * ```
5801
+ * // user is not authorized to make the change but may re-authenticate throw({ unauthorized: 'Error message here.'
5802
+ * });
5803
+ *
5804
+ * // change is not allowed throw({ forbidden: 'Error message here.' });
5805
+ * ```
5806
+ *
5807
+ * The function takes 4 parameters:
5808
+ *
5809
+ * * `newDoc` - New version of document that will be stored
5810
+ * from the update request.
5811
+ * * `oldDoc` - Previous version of document that is already stored.
5812
+ * * `userCtx` - User Context Object, containing information about the
5813
+ * user writing the document (if present), see the `UserContext`.
5814
+ * * `secObj` - Security Object, with lists of database security roles,
5815
+ * see the `SecurityObject`.
5816
+ */
5817
+ validate_doc_update?: string;
5826
5818
  /** Schema for design document views. */
5827
5819
  views?: JsonObject;
5828
5820
  /** Schema for geospatial index function definitions. */
@@ -5852,8 +5844,6 @@ declare namespace CloudantV1 {
5852
5844
  signature: string;
5853
5845
  /** Schema for size information of content. */
5854
5846
  sizes: ContentInformationSizes;
5855
- /** The update sequence of the corresponding database that has been indexed. */
5856
- update_seq: string;
5857
5847
  /** Indicates if the view is currently being updated. */
5858
5848
  updater_running: boolean;
5859
5849
  /** Number of clients waiting on views from this design document. */
@@ -6180,11 +6170,6 @@ declare namespace CloudantV1 {
6180
6170
  /** All cluster nodes. */
6181
6171
  cluster_nodes: string[];
6182
6172
  }
6183
- /** Schema for mapping document IDs to lists of missing revisions. */
6184
- interface MissingRevsResult {
6185
- /** Schema for mapping document IDs to lists of revisions. */
6186
- missing_revs: JsonObject;
6187
- }
6188
6173
  /** Schema for an OK result. */
6189
6174
  interface Ok {
6190
6175
  /** ok. */
@@ -6248,9 +6233,18 @@ declare namespace CloudantV1 {
6248
6233
  }
6249
6234
  /** Schema for replication source or target database authentication. */
6250
6235
  interface ReplicationDatabaseAuth {
6236
+ /** Schema for basic authentication of replication source or target database. */
6237
+ basic?: ReplicationDatabaseAuthBasic;
6251
6238
  /** Schema for an IAM API key for replication database authentication. */
6252
6239
  iam?: ReplicationDatabaseAuthIam;
6253
6240
  }
6241
+ /** Schema for basic authentication of replication source or target database. */
6242
+ interface ReplicationDatabaseAuthBasic {
6243
+ /** The password associated with the username. */
6244
+ password: string;
6245
+ /** The username. */
6246
+ username: string;
6247
+ }
6254
6248
  /** Schema for an IAM API key for replication database authentication. */
6255
6249
  interface ReplicationDatabaseAuthIam {
6256
6250
  /** IAM API key. */
@@ -6363,44 +6357,6 @@ declare namespace CloudantV1 {
6363
6357
  /** ReplicationDocument accepts additional properties. */
6364
6358
  [propName: string]: any;
6365
6359
  }
6366
- /** Schema for replication history information. */
6367
- interface ReplicationHistory {
6368
- /** Number of document write failures. */
6369
- doc_write_failures: number;
6370
- /** Number of documents read. */
6371
- docs_read: number;
6372
- /** Number of documents written to target. */
6373
- docs_written: number;
6374
- /** Last sequence number in changes stream. */
6375
- end_last_seq: string;
6376
- /** Date/Time replication operation completed in RFC 2822 format. */
6377
- end_time: string;
6378
- /** Number of missing documents checked. */
6379
- missing_checked: number;
6380
- /** Number of missing documents found. */
6381
- missing_found: number;
6382
- /** Last recorded sequence number. */
6383
- recorded_seq: string;
6384
- /** Session ID for this replication operation. */
6385
- session_id: string;
6386
- /** First sequence number in changes stream. */
6387
- start_last_seq: string;
6388
- /** Date/Time replication operation started in RFC 2822 format. */
6389
- start_time: string;
6390
- }
6391
- /** Schema for a replication result. */
6392
- interface ReplicationResult {
6393
- /** Replication history. */
6394
- history: ReplicationHistory[];
6395
- /** Replication status. */
6396
- ok: boolean;
6397
- /** Replication protocol version. */
6398
- replication_id_version: number;
6399
- /** Unique session ID. */
6400
- session_id: string;
6401
- /** Last sequence number read from source database. */
6402
- source_last_seq: string;
6403
- }
6404
6360
  /** Schema for list of revision information. */
6405
6361
  interface Revisions {
6406
6362
  /** Array of valid revision IDs, in reverse order (latest first). */
@@ -6512,6 +6468,8 @@ declare namespace CloudantV1 {
6512
6468
  }
6513
6469
  /** Schema for a replication scheduler job event. */
6514
6470
  interface SchedulerJobEvent {
6471
+ /** Reason for current state of event. */
6472
+ reason?: string;
6515
6473
  /** Timestamp of the event. */
6516
6474
  timestamp: string;
6517
6475
  /** Type of the event. */