@ibm-cloud/cloudant 0.8.3 → 0.9.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.
package/cloudant/v1.d.ts CHANGED
@@ -2667,8 +2667,10 @@ declare namespace CloudantV1 {
2667
2667
  interface EmptyObject {
2668
2668
  }
2669
2669
  /** A standard JS object, defined to avoid the limitations of `Object` and `object` */
2670
- interface JsonObject {
2670
+ class JsonObject {
2671
2671
  [key: string]: any;
2672
+ static serialize(obj: any): any;
2673
+ static deserialize(obj: any): any;
2672
2674
  }
2673
2675
  /*************************
2674
2676
  * request interfaces
@@ -5589,21 +5591,21 @@ declare namespace CloudantV1 {
5589
5591
  * model interfaces
5590
5592
  ************************/
5591
5593
  /** Schema for information about a running task. */
5592
- interface ActiveTask {
5594
+ class ActiveTask {
5593
5595
  /** The total count of attempted doc revisions fetched with `_bulk_get`. Available for `replication` type tasks. */
5594
- bulk_get_attempts?: number;
5596
+ bulkGetAttempts?: number;
5595
5597
  /** The total count of successful docs fetched with `_bulk_get`. Available for `replication` type tasks. */
5596
- bulk_get_docs?: number;
5598
+ bulkGetDocs?: number;
5597
5599
  /** Processed changes. Available for `database_compaction`, `indexer`, `search_indexer`, `view_compaction` type
5598
5600
  * tasks.
5599
5601
  */
5600
- changes_done?: number;
5602
+ changesDone?: number;
5601
5603
  /** The count of changes not yet replicated. Available for `replication` type tasks. */
5602
- changes_pending?: number;
5604
+ changesPending?: number;
5603
5605
  /** Specifies the checkpoint interval in ms. Available for `replication` type tasks. */
5604
- checkpoint_interval?: number;
5606
+ checkpointInterval?: number;
5605
5607
  /** The source sequence id which was last successfully replicated. Available for `replication` type tasks. */
5606
- checkpointed_source_seq?: string;
5608
+ checkpointedSourceSeq?: string;
5607
5609
  /** The replication configured to be continuous. Available for `replication` type tasks. */
5608
5610
  continuous?: boolean;
5609
5611
  /** Source database. */
@@ -5611,21 +5613,21 @@ declare namespace CloudantV1 {
5611
5613
  /** The design document that belongs to this task. Available for `indexer`, `search_indexer`, `view_compaction`
5612
5614
  * type tasks.
5613
5615
  */
5614
- design_document?: string;
5616
+ designDocument?: string;
5615
5617
  /** Replication document ID. Available for `replication` type tasks. */
5616
- doc_id?: string;
5618
+ docId?: string;
5617
5619
  /** Number of document write failures. Available for `replication` type tasks. */
5618
- doc_write_failures?: number;
5620
+ docWriteFailures?: number;
5619
5621
  /** Number of documents read. Available for `replication` type tasks. */
5620
- docs_read?: number;
5622
+ docsRead?: number;
5621
5623
  /** Number of documents written to target. Available for `replication` type tasks. */
5622
- docs_written?: number;
5624
+ docsWritten?: number;
5623
5625
  /** The search index that belongs to this task. Available for `search_indexer` type tasks. */
5624
5626
  index?: string;
5625
5627
  /** Indexer process ID. Available for `indexer` type tasks. */
5626
- indexer_pid?: string;
5628
+ indexerPid?: string;
5627
5629
  /** The count of docs which have been read from the source. Available for `replication` type tasks. */
5628
- missing_revisions_found?: number;
5630
+ missingRevisionsFound?: number;
5629
5631
  /** Cluster node where the task is running. */
5630
5632
  node: string;
5631
5633
  /** The phase the active task is in. `docid_sort`, `docid_copy`, `document_copy` phases are available for
@@ -5635,13 +5637,13 @@ declare namespace CloudantV1 {
5635
5637
  /** Process ID. */
5636
5638
  pid: string;
5637
5639
  /** Process status. */
5638
- process_status?: ActiveTask.Constants.ProcessStatus | string;
5640
+ processStatus?: ActiveTask.Constants.ProcessStatus | string;
5639
5641
  /** Current percentage progress. Available for `database_compaction`, `indexer`, `search_indexer`,
5640
5642
  * `view_compaction` type tasks.
5641
5643
  */
5642
5644
  progress?: number;
5643
5645
  /** Replication ID. Available for `replication` type tasks. */
5644
- replication_id?: string;
5646
+ replicationId?: string;
5645
5647
  /** Indicates whether a compaction retry is currently running on the database. Available for
5646
5648
  * `database_compaction` type tasks.
5647
5649
  */
@@ -5649,31 +5651,33 @@ declare namespace CloudantV1 {
5649
5651
  /** The count of revisions which have been checked since this replication began. Available for `replication`
5650
5652
  * type tasks.
5651
5653
  */
5652
- revisions_checked?: number;
5654
+ revisionsChecked?: number;
5653
5655
  /** Replication source. Available for `replication` type tasks. */
5654
5656
  source?: string;
5655
5657
  /** The last sequence number obtained from the source database changes feed. Available for `replication` type
5656
5658
  * tasks.
5657
5659
  */
5658
- source_seq?: string;
5660
+ sourceSeq?: string;
5659
5661
  /** Schema for a Unix epoch timestamp. */
5660
- started_on: number;
5662
+ startedOn: number;
5661
5663
  /** Replication target. Available for `replication` type tasks. */
5662
5664
  target?: string;
5663
5665
  /** The last sequence number processed by the replicator. Available for `replication` type tasks. */
5664
- through_seq?: string;
5666
+ throughSeq?: string;
5665
5667
  /** Total changes to process. Available for `database_compaction`, `indexer`, `search_indexer`,
5666
5668
  * `view_compaction` type tasks.
5667
5669
  */
5668
- total_changes?: number;
5670
+ totalChanges?: number;
5669
5671
  /** Operation type. */
5670
5672
  type: ActiveTask.Constants.Type | string;
5671
5673
  /** Schema for a Unix epoch timestamp. */
5672
- updated_on: number;
5674
+ updatedOn: number;
5673
5675
  /** Name of user running replication or owning the indexer. Available for `indexer`, `replication` type tasks. */
5674
- user?: string;
5676
+ user?: string | null;
5675
5677
  /** Number of view indexes. Available for `view_compaction` type tasks. */
5676
5678
  view?: number;
5679
+ static serialize(obj: any): ActiveTask.Transport;
5680
+ static deserialize(obj: any): ActiveTask;
5677
5681
  }
5678
5682
  namespace ActiveTask {
5679
5683
  namespace Constants {
@@ -5703,13 +5707,51 @@ declare namespace CloudantV1 {
5703
5707
  VIEW_COMPACTION = "view_compaction"
5704
5708
  }
5705
5709
  }
5710
+ interface Transport {
5711
+ bulk_get_attempts?: number;
5712
+ bulk_get_docs?: number;
5713
+ changes_done?: number;
5714
+ changes_pending?: number;
5715
+ checkpoint_interval?: number;
5716
+ checkpointed_source_seq?: string;
5717
+ continuous?: boolean;
5718
+ database: string;
5719
+ design_document?: string;
5720
+ doc_id?: string;
5721
+ doc_write_failures?: number;
5722
+ docs_read?: number;
5723
+ docs_written?: number;
5724
+ index?: string;
5725
+ indexer_pid?: string;
5726
+ missing_revisions_found?: number;
5727
+ node: string;
5728
+ phase?: string;
5729
+ pid: string;
5730
+ process_status?: string;
5731
+ progress?: number;
5732
+ replication_id?: string;
5733
+ retry?: boolean;
5734
+ revisions_checked?: number;
5735
+ source?: string;
5736
+ source_seq?: string;
5737
+ started_on: number;
5738
+ target?: string;
5739
+ through_seq?: string;
5740
+ total_changes?: number;
5741
+ type: string;
5742
+ updated_on: number;
5743
+ user?: string;
5744
+ view?: number;
5745
+ }
5706
5746
  }
5707
5747
  /** Schema for Activity Tracker events. */
5708
- interface ActivityTrackerEvents {
5748
+ class ActivityTrackerEvents {
5709
5749
  /** An array of event types that are being sent to IBM Cloud Activity Tracker for the IBM Cloudant instance.
5710
5750
  * "management" is a required element of this array.
5711
5751
  */
5712
5752
  types: ActivityTrackerEvents.Constants.Types[] | string[];
5753
+ static serialize(obj: any): ActivityTrackerEvents.Transport;
5754
+ static deserialize(obj: any): ActivityTrackerEvents;
5713
5755
  }
5714
5756
  namespace ActivityTrackerEvents {
5715
5757
  namespace Constants {
@@ -5719,20 +5761,30 @@ declare namespace CloudantV1 {
5719
5761
  DATA = "data"
5720
5762
  }
5721
5763
  }
5764
+ interface Transport {
5765
+ types: string[];
5766
+ }
5722
5767
  }
5723
5768
  /** Schema for the result of an all documents queries operation. */
5724
- interface AllDocsQueriesResult {
5769
+ class AllDocsQueriesResult {
5725
5770
  /** An array of result objects - one for each query. Each result object contains the same fields as the response
5726
5771
  * to a regular `/_all_docs` request.
5727
5772
  */
5728
5773
  results: AllDocsResult[];
5774
+ static serialize(obj: any): AllDocsQueriesResult.Transport;
5775
+ static deserialize(obj: any): AllDocsQueriesResult;
5776
+ }
5777
+ namespace AllDocsQueriesResult {
5778
+ interface Transport {
5779
+ results: AllDocsResult[];
5780
+ }
5729
5781
  }
5730
5782
  /** Schema for an all documents query operation. */
5731
- interface AllDocsQuery {
5783
+ class AllDocsQuery {
5732
5784
  /** Parameter to specify whether to include the encoding information in attachment stubs if the particular
5733
5785
  * attachment is compressed.
5734
5786
  */
5735
- att_encoding_info?: boolean;
5787
+ attEncodingInfo?: boolean;
5736
5788
  /** Parameter to specify whether to include attachments bodies in a response. */
5737
5789
  attachments?: boolean;
5738
5790
  /** Parameter to specify whether to include a list of conflicted revisions in each returned document. Active
@@ -5742,9 +5794,9 @@ declare namespace CloudantV1 {
5742
5794
  /** Parameter to specify whether to return the documents in descending by key order. */
5743
5795
  descending?: boolean;
5744
5796
  /** Parameter to specify whether to include the full content of the documents in the response. */
5745
- include_docs?: boolean;
5797
+ includeDocs?: boolean;
5746
5798
  /** Parameter to specify whether the specified end key should be included in the result. */
5747
- inclusive_end?: boolean;
5799
+ inclusiveEnd?: boolean;
5748
5800
  /** Parameter to specify the number of returned documents to limit the result to. */
5749
5801
  limit?: number;
5750
5802
  /** Parameter to specify the number of records before starting to return the results. */
@@ -5752,27 +5804,55 @@ declare namespace CloudantV1 {
5752
5804
  /** Parameter to specify whether to include in the response an update_seq value indicating the sequence id of
5753
5805
  * the database the view reflects.
5754
5806
  */
5755
- update_seq?: boolean;
5807
+ updateSeq?: boolean;
5756
5808
  /** Schema for a document ID. */
5757
- end_key?: string;
5809
+ endKey?: string;
5758
5810
  /** Schema for a document ID. */
5759
5811
  key?: string;
5760
5812
  /** Schema for a list of document IDs. */
5761
5813
  keys?: string[];
5762
5814
  /** Schema for a document ID. */
5763
- start_key?: string;
5815
+ startKey?: string;
5816
+ static serialize(obj: any): AllDocsQuery.Transport;
5817
+ static deserialize(obj: any): AllDocsQuery;
5818
+ }
5819
+ namespace AllDocsQuery {
5820
+ interface Transport {
5821
+ att_encoding_info?: boolean;
5822
+ attachments?: boolean;
5823
+ conflicts?: boolean;
5824
+ descending?: boolean;
5825
+ include_docs?: boolean;
5826
+ inclusive_end?: boolean;
5827
+ limit?: number;
5828
+ skip?: number;
5829
+ update_seq?: boolean;
5830
+ end_key?: string;
5831
+ key?: string;
5832
+ keys?: string[];
5833
+ start_key?: string;
5834
+ }
5764
5835
  }
5765
5836
  /** Schema for the result of an all documents operation. */
5766
- interface AllDocsResult {
5837
+ class AllDocsResult {
5767
5838
  /** Number of total rows. */
5768
- total_rows: number;
5839
+ totalRows: number | null;
5769
5840
  /** List of doc results. */
5770
5841
  rows: DocsResultRow[];
5771
5842
  /** Current update sequence for the database. */
5772
- update_seq?: string;
5843
+ updateSeq?: string;
5844
+ static serialize(obj: any): AllDocsResult.Transport;
5845
+ static deserialize(obj: any): AllDocsResult;
5846
+ }
5847
+ namespace AllDocsResult {
5848
+ interface Transport {
5849
+ total_rows: number;
5850
+ rows: DocsResultRow[];
5851
+ update_seq?: string;
5852
+ }
5773
5853
  }
5774
5854
  /** Schema for a full text search analyzer. */
5775
- interface Analyzer {
5855
+ class Analyzer {
5776
5856
  /** Schema for the name of the Apache Lucene analyzer to use for text indexing. The default value varies
5777
5857
  * depending on the analyzer usage:
5778
5858
  * * For search indexes the default is `standard` * For query text indexes the default is `keyword` * For a query
@@ -5781,6 +5861,8 @@ declare namespace CloudantV1 {
5781
5861
  name?: Analyzer.Constants.Name | string;
5782
5862
  /** Custom stopwords to use with the named analyzer. */
5783
5863
  stopwords?: string[];
5864
+ static serialize(obj: any): Analyzer.Transport;
5865
+ static deserialize(obj: any): Analyzer;
5784
5866
  }
5785
5867
  namespace Analyzer {
5786
5868
  namespace Constants {
@@ -5829,9 +5911,13 @@ declare namespace CloudantV1 {
5829
5911
  PERFIELD = "perfield"
5830
5912
  }
5831
5913
  }
5914
+ interface Transport {
5915
+ name?: string;
5916
+ stopwords?: string[];
5917
+ }
5832
5918
  }
5833
5919
  /** Schema for a search analyzer configuration. */
5834
- interface AnalyzerConfiguration {
5920
+ class AnalyzerConfiguration {
5835
5921
  /** Schema for the name of the Apache Lucene analyzer to use for text indexing. The default value varies
5836
5922
  * depending on the analyzer usage:
5837
5923
  * * For search indexes the default is `standard` * For query text indexes the default is `keyword` * For a query
@@ -5841,7 +5927,11 @@ declare namespace CloudantV1 {
5841
5927
  /** Custom stopwords to use with the named analyzer. */
5842
5928
  stopwords?: string[];
5843
5929
  /** Schema for mapping a field name to a per field analyzer. */
5844
- fields?: JsonObject;
5930
+ fields?: {
5931
+ [key: string]: Analyzer;
5932
+ };
5933
+ static serialize(obj: any): AnalyzerConfiguration.Transport;
5934
+ static deserialize(obj: any): AnalyzerConfiguration;
5845
5935
  }
5846
5936
  namespace AnalyzerConfiguration {
5847
5937
  namespace Constants {
@@ -5890,20 +5980,36 @@ declare namespace CloudantV1 {
5890
5980
  PERFIELD = "perfield"
5891
5981
  }
5892
5982
  }
5983
+ interface Transport {
5984
+ name?: string;
5985
+ stopwords?: string[];
5986
+ fields?: {
5987
+ [key: string]: Analyzer.Transport;
5988
+ };
5989
+ }
5893
5990
  }
5894
5991
  /** Schema for api keys. */
5895
- interface ApiKeysResult {
5992
+ class ApiKeysResult {
5896
5993
  /** ok. */
5897
5994
  ok: boolean;
5898
5995
  /** The generated api key. */
5899
5996
  key: string;
5900
5997
  /** The password associated with the api key. */
5901
5998
  password: string;
5999
+ static serialize(obj: any): ApiKeysResult.Transport;
6000
+ static deserialize(obj: any): ApiKeysResult;
6001
+ }
6002
+ namespace ApiKeysResult {
6003
+ interface Transport {
6004
+ ok: boolean;
6005
+ key: string;
6006
+ password: string;
6007
+ }
5902
6008
  }
5903
6009
  /** Schema for an attachment. */
5904
- interface Attachment {
6010
+ class Attachment {
5905
6011
  /** Attachment MIME type. */
5906
- content_type?: string;
6012
+ contentType?: string;
5907
6013
  /** Base64-encoded content. Available if attachment content is requested by using the query parameters
5908
6014
  * `attachments=true` or `atts_since`. Note that when used with a view or changes feed `include_docs` must also be
5909
6015
  * `true`.
@@ -5917,7 +6023,7 @@ declare namespace CloudantV1 {
5917
6023
  * attachment was added and the query parameter `att_encoding_info` is `true`. Note that when used with a view or
5918
6024
  * changes feed `include_docs` must also be `true`.
5919
6025
  */
5920
- encoded_length?: number;
6026
+ encodedLength?: number;
5921
6027
  /** Compression codec. Available if content_type was in list of compressible types when the attachment was added
5922
6028
  * and the and the query parameter `att_encoding_info` is `true`. Note that when used with a view or changes feed
5923
6029
  * `include_docs` must also be `true`.
@@ -5931,79 +6037,172 @@ declare namespace CloudantV1 {
5931
6037
  revpos?: number;
5932
6038
  /** Has `true` value if object contains stub info and no content. Otherwise omitted in response. */
5933
6039
  stub?: boolean;
6040
+ static serialize(obj: any): Attachment.Transport;
6041
+ static deserialize(obj: any): Attachment;
6042
+ }
6043
+ namespace Attachment {
6044
+ interface Transport {
6045
+ content_type?: string;
6046
+ data?: string;
6047
+ digest?: string;
6048
+ encoded_length?: number;
6049
+ encoding?: string;
6050
+ follows?: boolean;
6051
+ length?: number;
6052
+ revpos?: number;
6053
+ stub?: boolean;
6054
+ }
5934
6055
  }
5935
6056
  /** Schema for submitting documents for bulk modifications. */
5936
- interface BulkDocs {
6057
+ class BulkDocs {
5937
6058
  /** Array of documents. */
5938
6059
  docs: Document[];
5939
6060
  /** If `false`, prevents the database from assigning them new revision IDs. Default is `true`. */
5940
- new_edits?: boolean;
6061
+ newEdits?: boolean;
6062
+ static serialize(obj: any): BulkDocs.Transport;
6063
+ static deserialize(obj: any): BulkDocs;
6064
+ }
6065
+ namespace BulkDocs {
6066
+ interface Transport {
6067
+ docs: Document[];
6068
+ new_edits?: boolean;
6069
+ }
5941
6070
  }
5942
6071
  /** Schema for a document item in a bulk get query. */
5943
- interface BulkGetQueryDocument {
6072
+ class BulkGetQueryDocument {
5944
6073
  /** Includes attachments only since specified revisions. */
5945
- atts_since?: string[];
6074
+ attsSince?: string[];
5946
6075
  /** Schema for a document ID. */
5947
6076
  id: string;
5948
6077
  /** Schema for a document revision identifier. */
5949
6078
  rev?: string;
6079
+ static serialize(obj: any): BulkGetQueryDocument.Transport;
6080
+ static deserialize(obj: any): BulkGetQueryDocument;
6081
+ }
6082
+ namespace BulkGetQueryDocument {
6083
+ interface Transport {
6084
+ atts_since?: string[];
6085
+ id: string;
6086
+ rev?: string;
6087
+ }
5950
6088
  }
5951
6089
  /** Schema for the results object of a bulk get operation. */
5952
- interface BulkGetResult {
6090
+ class BulkGetResult {
5953
6091
  /** Results. */
5954
6092
  results: BulkGetResultItem[];
6093
+ static serialize(obj: any): BulkGetResult.Transport;
6094
+ static deserialize(obj: any): BulkGetResult;
6095
+ }
6096
+ namespace BulkGetResult {
6097
+ interface Transport {
6098
+ results: BulkGetResultItem[];
6099
+ }
5955
6100
  }
5956
6101
  /** Schema for BulkGetResult object containing a successfully retrieved document or error information. */
5957
- interface BulkGetResultDocument {
6102
+ class BulkGetResultDocument {
5958
6103
  /** Schema for the result of a document modification. */
5959
6104
  error?: DocumentResult;
5960
6105
  /** Schema for a document. */
5961
6106
  ok?: Document;
6107
+ static serialize(obj: any): BulkGetResultDocument.Transport;
6108
+ static deserialize(obj: any): BulkGetResultDocument;
6109
+ }
6110
+ namespace BulkGetResultDocument {
6111
+ interface Transport {
6112
+ error?: DocumentResult.Transport;
6113
+ ok?: Document.Transport;
6114
+ }
5962
6115
  }
5963
6116
  /** Schema for the document revisions information from a bulk get operation. */
5964
- interface BulkGetResultItem {
6117
+ class BulkGetResultItem {
5965
6118
  /** Array of document revisions or error information. */
5966
6119
  docs: BulkGetResultDocument[];
5967
6120
  /** Schema for a document ID. */
5968
6121
  id: string;
6122
+ static serialize(obj: any): BulkGetResultItem.Transport;
6123
+ static deserialize(obj: any): BulkGetResultItem;
6124
+ }
6125
+ namespace BulkGetResultItem {
6126
+ interface Transport {
6127
+ docs: BulkGetResultDocument[];
6128
+ id: string;
6129
+ }
5969
6130
  }
5970
6131
  /** Schema for information about the currently provisioned and target throughput capacity. */
5971
- interface CapacityThroughputInformation {
6132
+ class CapacityThroughputInformation {
5972
6133
  /** Detailed information about provisioned throughput capacity. */
5973
6134
  current: CapacityThroughputInformationCurrent;
5974
6135
  /** Detailed information about target throughput capacity. */
5975
6136
  target?: CapacityThroughputInformationTarget;
6137
+ static serialize(obj: any): CapacityThroughputInformation.Transport;
6138
+ static deserialize(obj: any): CapacityThroughputInformation;
6139
+ }
6140
+ namespace CapacityThroughputInformation {
6141
+ interface Transport {
6142
+ current: CapacityThroughputInformationCurrent.Transport;
6143
+ target?: CapacityThroughputInformationTarget.Transport;
6144
+ }
5976
6145
  }
5977
6146
  /** Detailed information about provisioned throughput capacity. */
5978
- interface CapacityThroughputInformationCurrent {
6147
+ class CapacityThroughputInformationCurrent {
5979
6148
  /** Schema for detailed information about throughput capacity with breakdown by specific throughput requests
5980
6149
  * classes.
5981
6150
  */
5982
6151
  throughput: ThroughputInformation;
6152
+ static serialize(obj: any): CapacityThroughputInformationCurrent.Transport;
6153
+ static deserialize(obj: any): CapacityThroughputInformationCurrent;
6154
+ }
6155
+ namespace CapacityThroughputInformationCurrent {
6156
+ interface Transport {
6157
+ throughput: ThroughputInformation.Transport;
6158
+ }
5983
6159
  }
5984
6160
  /** Detailed information about target throughput capacity. */
5985
- interface CapacityThroughputInformationTarget {
6161
+ class CapacityThroughputInformationTarget {
5986
6162
  /** Schema for detailed information about throughput capacity with breakdown by specific throughput requests
5987
6163
  * classes.
5988
6164
  */
5989
6165
  throughput: ThroughputInformation;
6166
+ static serialize(obj: any): CapacityThroughputInformationTarget.Transport;
6167
+ static deserialize(obj: any): CapacityThroughputInformationTarget;
6168
+ }
6169
+ namespace CapacityThroughputInformationTarget {
6170
+ interface Transport {
6171
+ throughput: ThroughputInformation.Transport;
6172
+ }
5990
6173
  }
5991
6174
  /** Schema for a document leaf with single field rev. */
5992
- interface Change {
6175
+ class Change {
5993
6176
  /** Schema for a document revision identifier. */
5994
6177
  rev: string;
6178
+ static serialize(obj: any): Change.Transport;
6179
+ static deserialize(obj: any): Change;
6180
+ }
6181
+ namespace Change {
6182
+ interface Transport {
6183
+ rev: string;
6184
+ }
5995
6185
  }
5996
6186
  /** Schema for normal changes feed result. */
5997
- interface ChangesResult {
6187
+ class ChangesResult {
5998
6188
  /** last_seq. */
5999
- last_seq: string;
6189
+ lastSeq: string;
6000
6190
  /** pending. */
6001
6191
  pending: number;
6002
6192
  /** results. */
6003
6193
  results: ChangesResultItem[];
6194
+ static serialize(obj: any): ChangesResult.Transport;
6195
+ static deserialize(obj: any): ChangesResult;
6196
+ }
6197
+ namespace ChangesResult {
6198
+ interface Transport {
6199
+ last_seq: string;
6200
+ pending: number;
6201
+ results: ChangesResultItem[];
6202
+ }
6004
6203
  }
6005
6204
  /** Schema for an item in the changes results array. */
6006
- interface ChangesResultItem {
6205
+ class ChangesResultItem {
6007
6206
  /** List of document's leaves with single field rev. */
6008
6207
  changes: Change[];
6009
6208
  /** if `true` then the document is deleted. */
@@ -6014,62 +6213,107 @@ declare namespace CloudantV1 {
6014
6213
  id: string;
6015
6214
  /** Update sequence. */
6016
6215
  seq: string;
6216
+ static serialize(obj: any): ChangesResultItem.Transport;
6217
+ static deserialize(obj: any): ChangesResultItem;
6218
+ }
6219
+ namespace ChangesResultItem {
6220
+ interface Transport {
6221
+ changes: Change[];
6222
+ deleted?: boolean;
6223
+ doc?: Document.Transport;
6224
+ id: string;
6225
+ seq: string;
6226
+ }
6017
6227
  }
6018
6228
  /** Schema for size information of content. */
6019
- interface ContentInformationSizes {
6229
+ class ContentInformationSizes {
6020
6230
  /** The active size of the content, in bytes. */
6021
6231
  active: number;
6022
6232
  /** The total uncompressed size of the content, in bytes. */
6023
6233
  external: number;
6024
6234
  /** The total size of the content as stored on disk, in bytes. */
6025
6235
  file: number;
6236
+ static serialize(obj: any): ContentInformationSizes.Transport;
6237
+ static deserialize(obj: any): ContentInformationSizes;
6238
+ }
6239
+ namespace ContentInformationSizes {
6240
+ interface Transport {
6241
+ active: number;
6242
+ external: number;
6243
+ file: number;
6244
+ }
6026
6245
  }
6027
6246
  /** Schema for information about the CORS configuration. */
6028
- interface CorsInformation {
6247
+ class CorsInformation {
6029
6248
  /** Boolean value to allow authentication credentials. If set to true, browser requests must be done by using
6030
6249
  * withCredentials = true.
6031
6250
  */
6032
- allow_credentials: boolean;
6251
+ allowCredentials: boolean;
6033
6252
  /** Boolean value to turn CORS on and off. */
6034
- enable_cors: boolean;
6253
+ enableCors: boolean;
6035
6254
  /** An array of strings that contain allowed origin domains. You have to specify the full URL including the
6036
6255
  * protocol. It is recommended that only the HTTPS protocol is used. Subdomains count as separate domains, so you
6037
6256
  * have to specify all subdomains used.
6038
6257
  */
6039
6258
  origins: string[];
6259
+ static serialize(obj: any): CorsInformation.Transport;
6260
+ static deserialize(obj: any): CorsInformation;
6261
+ }
6262
+ namespace CorsInformation {
6263
+ interface Transport {
6264
+ allow_credentials: boolean;
6265
+ enable_cors: boolean;
6266
+ origins: string[];
6267
+ }
6040
6268
  }
6041
6269
  /** Schema for information about current consumption of a provisioned throughput capacity. */
6042
- interface CurrentThroughputInformation {
6270
+ class CurrentThroughputInformation {
6043
6271
  /** Detailed information about current consumption. */
6044
6272
  throughput: CurrentThroughputInformationThroughput;
6273
+ static serialize(obj: any): CurrentThroughputInformation.Transport;
6274
+ static deserialize(obj: any): CurrentThroughputInformation;
6275
+ }
6276
+ namespace CurrentThroughputInformation {
6277
+ interface Transport {
6278
+ throughput: CurrentThroughputInformationThroughput.Transport;
6279
+ }
6045
6280
  }
6046
6281
  /** Detailed information about current consumption. */
6047
- interface CurrentThroughputInformationThroughput {
6282
+ class CurrentThroughputInformationThroughput {
6048
6283
  /** Number of global queries conducted against the instance for a given second. */
6049
6284
  query: number;
6050
6285
  /** Number of reads conducted against the instance for a given second. */
6051
6286
  read: number;
6052
6287
  /** Number of writes conducted against the instance for a given second. */
6053
6288
  write: number;
6289
+ static serialize(obj: any): CurrentThroughputInformationThroughput.Transport;
6290
+ static deserialize(obj: any): CurrentThroughputInformationThroughput;
6291
+ }
6292
+ namespace CurrentThroughputInformationThroughput {
6293
+ interface Transport {
6294
+ query: number;
6295
+ read: number;
6296
+ write: number;
6297
+ }
6054
6298
  }
6055
6299
  /** Schema for information about a database. */
6056
- interface DatabaseInformation {
6300
+ class DatabaseInformation {
6057
6301
  /** Schema for database cluster information. */
6058
6302
  cluster: DatabaseInformationCluster;
6059
6303
  /** An opaque string that describes the committed state of the database. */
6060
- committed_update_seq?: string;
6304
+ committedUpdateSeq?: string;
6061
6305
  /** True if the database compaction routine is operating on this database. */
6062
- compact_running: boolean;
6306
+ compactRunning: boolean;
6063
6307
  /** An opaque string that describes the compaction state of the database. */
6064
- compacted_seq?: string;
6308
+ compactedSeq?: string;
6065
6309
  /** The name of the database. */
6066
- db_name: string;
6310
+ dbName: string;
6067
6311
  /** The version of the physical format used for the data when it is stored on disk. */
6068
- disk_format_version: number;
6312
+ diskFormatVersion: number;
6069
6313
  /** A count of the documents in the specified database. */
6070
- doc_count: number;
6314
+ docCount: number;
6071
6315
  /** Number of deleted documents. */
6072
- doc_del_count: number;
6316
+ docDelCount: number;
6073
6317
  /** The engine used for the database. */
6074
6318
  engine?: string;
6075
6319
  /** Schema for database properties. */
@@ -6079,14 +6323,34 @@ declare namespace CloudantV1 {
6079
6323
  /** An opaque string that describes the state of the database. Do not rely on this string for counting the
6080
6324
  * number of updates.
6081
6325
  */
6082
- update_seq: string;
6326
+ updateSeq: string;
6083
6327
  /** The UUID of the database. */
6084
6328
  uuid?: string;
6085
6329
  /** Information about database's partitioned indexes. */
6086
- partitioned_indexes?: PartitionedIndexesInformation;
6330
+ partitionedIndexes?: PartitionedIndexesInformation;
6331
+ static serialize(obj: any): DatabaseInformation.Transport;
6332
+ static deserialize(obj: any): DatabaseInformation;
6333
+ }
6334
+ namespace DatabaseInformation {
6335
+ interface Transport {
6336
+ cluster: DatabaseInformationCluster.Transport;
6337
+ committed_update_seq?: string;
6338
+ compact_running: boolean;
6339
+ compacted_seq?: string;
6340
+ db_name: string;
6341
+ disk_format_version: number;
6342
+ doc_count: number;
6343
+ doc_del_count: number;
6344
+ engine?: string;
6345
+ props: DatabaseInformationProps.Transport;
6346
+ sizes: ContentInformationSizes.Transport;
6347
+ update_seq: string;
6348
+ uuid?: string;
6349
+ partitioned_indexes?: PartitionedIndexesInformation.Transport;
6350
+ }
6087
6351
  }
6088
6352
  /** Schema for database cluster information. */
6089
- interface DatabaseInformationCluster {
6353
+ class DatabaseInformationCluster {
6090
6354
  /** Schema for the number of replicas of a database in a cluster. The cluster is using the default value and it
6091
6355
  * cannot be changed by the user.
6092
6356
  */
@@ -6097,20 +6361,39 @@ declare namespace CloudantV1 {
6097
6361
  r: number;
6098
6362
  /** Write quorum. The number of copies of a document that need to be written before a successful reply. */
6099
6363
  w: number;
6364
+ static serialize(obj: any): DatabaseInformationCluster.Transport;
6365
+ static deserialize(obj: any): DatabaseInformationCluster;
6366
+ }
6367
+ namespace DatabaseInformationCluster {
6368
+ interface Transport {
6369
+ n: number;
6370
+ q: number;
6371
+ r: number;
6372
+ w: number;
6373
+ }
6100
6374
  }
6101
6375
  /** Schema for database properties. */
6102
- interface DatabaseInformationProps {
6376
+ class DatabaseInformationProps {
6103
6377
  /** The value is `true` for a partitioned database. */
6104
6378
  partitioned?: boolean;
6379
+ static serialize(obj: any): DatabaseInformationProps.Transport;
6380
+ static deserialize(obj: any): DatabaseInformationProps;
6381
+ }
6382
+ namespace DatabaseInformationProps {
6383
+ interface Transport {
6384
+ partitioned?: boolean;
6385
+ }
6105
6386
  }
6106
6387
  /** Schema for a database change event. */
6107
- interface DbEvent {
6388
+ class DbEvent {
6108
6389
  /** Database name. */
6109
- db_name: string;
6390
+ dbName: string;
6110
6391
  /** Sequence number. */
6111
6392
  seq: string;
6112
6393
  /** A database event. */
6113
6394
  type: DbEvent.Constants.Type | string;
6395
+ static serialize(obj: any): DbEvent.Transport;
6396
+ static deserialize(obj: any): DbEvent;
6114
6397
  }
6115
6398
  namespace DbEvent {
6116
6399
  namespace Constants {
@@ -6121,27 +6404,51 @@ declare namespace CloudantV1 {
6121
6404
  UPDATED = "updated"
6122
6405
  }
6123
6406
  }
6407
+ interface Transport {
6408
+ db_name: string;
6409
+ seq: string;
6410
+ type: string;
6411
+ }
6124
6412
  }
6125
6413
  /** Schema for database updates. */
6126
- interface DbUpdates {
6414
+ class DbUpdates {
6127
6415
  /** Last sequence number. */
6128
- last_seq: string;
6416
+ lastSeq: string;
6129
6417
  /** results. */
6130
6418
  results: DbEvent[];
6419
+ static serialize(obj: any): DbUpdates.Transport;
6420
+ static deserialize(obj: any): DbUpdates;
6421
+ }
6422
+ namespace DbUpdates {
6423
+ interface Transport {
6424
+ last_seq: string;
6425
+ results: DbEvent[];
6426
+ }
6131
6427
  }
6132
6428
  /** Schema for database information keyed by database name. */
6133
- interface DbsInfoResult {
6429
+ class DbsInfoResult {
6134
6430
  /** The name of the error. */
6135
6431
  error?: string;
6136
6432
  /** Schema for information about a database. */
6137
6433
  info?: DatabaseInformation;
6138
6434
  /** Database name. */
6139
6435
  key: string;
6436
+ static serialize(obj: any): DbsInfoResult.Transport;
6437
+ static deserialize(obj: any): DbsInfoResult;
6438
+ }
6439
+ namespace DbsInfoResult {
6440
+ interface Transport {
6441
+ error?: string;
6442
+ info?: DatabaseInformation.Transport;
6443
+ key: string;
6444
+ }
6140
6445
  }
6141
6446
  /** Schema for a design document. */
6142
- interface DesignDocument {
6447
+ class DesignDocument {
6143
6448
  /** Schema for a map of attachment name to attachment metadata. */
6144
- _attachments?: JsonObject;
6449
+ _attachments?: {
6450
+ [key: string]: Attachment;
6451
+ };
6145
6452
  /** Schema for a list of document revision identifiers. */
6146
6453
  _conflicts?: string[];
6147
6454
  /** Deletion flag. Available if document was removed. */
@@ -6204,7 +6511,9 @@ declare namespace CloudantV1 {
6204
6511
  */
6205
6512
  filters?: JsonObject;
6206
6513
  /** Search (text) index function definitions. */
6207
- indexes?: JsonObject;
6514
+ indexes?: {
6515
+ [key: string]: SearchIndexDefinition;
6516
+ };
6208
6517
  /** Defines Query Server key to process design document functions. */
6209
6518
  language?: string;
6210
6519
  /** Schema for design document options. */
@@ -6235,32 +6544,79 @@ declare namespace CloudantV1 {
6235
6544
  * * `secObj` - Security Object, with lists of database security roles,
6236
6545
  * see the `SecurityObject`.
6237
6546
  */
6238
- validate_doc_update?: string;
6547
+ validateDocUpdate?: string;
6239
6548
  /** Schema for design document views. */
6240
- views?: JsonObject;
6549
+ views?: {
6550
+ [key: string]: DesignDocumentViewsMapReduce;
6551
+ };
6241
6552
  /** DesignDocument accepts additional properties. */
6242
6553
  [propName: string]: any;
6554
+ static serialize(obj: any): DesignDocument.Transport;
6555
+ static deserialize(obj: any): DesignDocument;
6556
+ }
6557
+ namespace DesignDocument {
6558
+ interface Transport {
6559
+ _attachments?: {
6560
+ [key: string]: Attachment.Transport;
6561
+ };
6562
+ _conflicts?: string[];
6563
+ _deleted?: boolean;
6564
+ _deleted_conflicts?: string[];
6565
+ _id?: string;
6566
+ _local_seq?: string;
6567
+ _rev?: string;
6568
+ _revisions?: Revisions.Transport;
6569
+ _revs_info?: DocumentRevisionStatus[];
6570
+ autoupdate?: boolean;
6571
+ filters?: JsonObject;
6572
+ indexes?: {
6573
+ [key: string]: SearchIndexDefinition.Transport;
6574
+ };
6575
+ language?: string;
6576
+ options?: DesignDocumentOptions.Transport;
6577
+ validate_doc_update?: string;
6578
+ views?: {
6579
+ [key: string]: DesignDocumentViewsMapReduce.Transport;
6580
+ };
6581
+ /** DesignDocument.DesignDocument.Transport accepts additional properties. */
6582
+ [propName: string]: any;
6583
+ }
6243
6584
  }
6244
6585
  /** Schema for information about a design document. */
6245
- interface DesignDocumentInformation {
6586
+ class DesignDocumentInformation {
6246
6587
  /** name. */
6247
6588
  name: string;
6248
6589
  /** View index information. */
6249
- view_index: DesignDocumentViewIndex;
6590
+ viewIndex: DesignDocumentViewIndex;
6591
+ static serialize(obj: any): DesignDocumentInformation.Transport;
6592
+ static deserialize(obj: any): DesignDocumentInformation;
6593
+ }
6594
+ namespace DesignDocumentInformation {
6595
+ interface Transport {
6596
+ name: string;
6597
+ view_index: DesignDocumentViewIndex.Transport;
6598
+ }
6250
6599
  }
6251
6600
  /** Schema for design document options. */
6252
- interface DesignDocumentOptions {
6601
+ class DesignDocumentOptions {
6253
6602
  /** Whether this design document describes partitioned or global indexes. */
6254
6603
  partitioned?: boolean;
6604
+ static serialize(obj: any): DesignDocumentOptions.Transport;
6605
+ static deserialize(obj: any): DesignDocumentOptions;
6606
+ }
6607
+ namespace DesignDocumentOptions {
6608
+ interface Transport {
6609
+ partitioned?: boolean;
6610
+ }
6255
6611
  }
6256
6612
  /** View index information. */
6257
- interface DesignDocumentViewIndex {
6613
+ class DesignDocumentViewIndex {
6258
6614
  /** List of collator versions. If there are multiple entries this implies a libicu upgrade has occurred but
6259
6615
  * compaction has not run yet.
6260
6616
  */
6261
- collator_versions: string[];
6617
+ collatorVersions: string[];
6262
6618
  /** Indicates whether a compaction routine is currently running on the view. */
6263
- compact_running: boolean;
6619
+ compactRunning: boolean;
6264
6620
  /** Language for the defined views. */
6265
6621
  language: string;
6266
6622
  /** MD5 signature of the views for the design document. */
@@ -6268,25 +6624,48 @@ declare namespace CloudantV1 {
6268
6624
  /** Schema for size information of content. */
6269
6625
  sizes: ContentInformationSizes;
6270
6626
  /** Indicates if the view is currently being updated. */
6271
- updater_running: boolean;
6627
+ updaterRunning: boolean;
6272
6628
  /** Schema for an ability to tell if view is up-to-date without querying it. */
6273
- updates_pending: UpdatesPending;
6629
+ updatesPending: UpdatesPending;
6274
6630
  /** Number of clients waiting on views from this design document. */
6275
- waiting_clients: number;
6631
+ waitingClients: number;
6276
6632
  /** Indicates if there are outstanding commits to the underlying database that need to processed. */
6277
- waiting_commit: boolean;
6633
+ waitingCommit: boolean;
6634
+ static serialize(obj: any): DesignDocumentViewIndex.Transport;
6635
+ static deserialize(obj: any): DesignDocumentViewIndex;
6636
+ }
6637
+ namespace DesignDocumentViewIndex {
6638
+ interface Transport {
6639
+ collator_versions: string[];
6640
+ compact_running: boolean;
6641
+ language: string;
6642
+ signature: string;
6643
+ sizes: ContentInformationSizes.Transport;
6644
+ updater_running: boolean;
6645
+ updates_pending: UpdatesPending.Transport;
6646
+ waiting_clients: number;
6647
+ waiting_commit: boolean;
6648
+ }
6278
6649
  }
6279
6650
  /** Schema for view functions definition. */
6280
- interface DesignDocumentViewsMapReduce {
6651
+ class DesignDocumentViewsMapReduce {
6281
6652
  /** JavaScript map function as a string. */
6282
6653
  map: string;
6283
6654
  /** JavaScript reduce function as a string. */
6284
6655
  reduce?: string;
6656
+ static serialize(obj: any): DesignDocumentViewsMapReduce.Transport;
6657
+ static deserialize(obj: any): DesignDocumentViewsMapReduce;
6658
+ }
6659
+ namespace DesignDocumentViewsMapReduce {
6660
+ interface Transport {
6661
+ map: string;
6662
+ reduce?: string;
6663
+ }
6285
6664
  }
6286
6665
  /** Schema for a row of document information in a DocsResult. */
6287
- interface DocsResultRow {
6666
+ class DocsResultRow {
6288
6667
  /** The cause of the error (if available). */
6289
- caused_by?: string;
6668
+ causedBy?: string;
6290
6669
  /** The name of the error. */
6291
6670
  error?: string;
6292
6671
  /** The reason the error occurred (if available). */
@@ -6299,18 +6678,41 @@ declare namespace CloudantV1 {
6299
6678
  key: string;
6300
6679
  /** Value of built-in `/_all_docs` style view. */
6301
6680
  value?: DocsResultRowValue;
6681
+ static serialize(obj: any): DocsResultRow.Transport;
6682
+ static deserialize(obj: any): DocsResultRow;
6683
+ }
6684
+ namespace DocsResultRow {
6685
+ interface Transport {
6686
+ caused_by?: string;
6687
+ error?: string;
6688
+ reason?: string;
6689
+ doc?: Document.Transport;
6690
+ id?: string;
6691
+ key: string;
6692
+ value?: DocsResultRowValue.Transport;
6693
+ }
6302
6694
  }
6303
6695
  /** Value of built-in `/_all_docs` style view. */
6304
- interface DocsResultRowValue {
6696
+ class DocsResultRowValue {
6305
6697
  /** If `true` then the document is deleted. Not present for undeleted documents. */
6306
6698
  deleted?: boolean;
6307
6699
  /** Schema for a document revision identifier. */
6308
6700
  rev: string;
6701
+ static serialize(obj: any): DocsResultRowValue.Transport;
6702
+ static deserialize(obj: any): DocsResultRowValue;
6703
+ }
6704
+ namespace DocsResultRowValue {
6705
+ interface Transport {
6706
+ deleted?: boolean;
6707
+ rev: string;
6708
+ }
6309
6709
  }
6310
6710
  /** Schema for a document. */
6311
- interface Document {
6711
+ class Document {
6312
6712
  /** Schema for a map of attachment name to attachment metadata. */
6313
- _attachments?: JsonObject;
6713
+ _attachments?: {
6714
+ [key: string]: Attachment;
6715
+ };
6314
6716
  /** Schema for a list of document revision identifiers. */
6315
6717
  _conflicts?: string[];
6316
6718
  /** Deletion flag. Available if document was removed. */
@@ -6329,9 +6731,28 @@ declare namespace CloudantV1 {
6329
6731
  _revs_info?: DocumentRevisionStatus[];
6330
6732
  /** Document accepts additional properties. */
6331
6733
  [propName: string]: any;
6734
+ static serialize(obj: any): Document.Transport;
6735
+ static deserialize(obj: any): Document;
6736
+ }
6737
+ namespace Document {
6738
+ interface Transport {
6739
+ _attachments?: {
6740
+ [key: string]: Attachment.Transport;
6741
+ };
6742
+ _conflicts?: string[];
6743
+ _deleted?: boolean;
6744
+ _deleted_conflicts?: string[];
6745
+ _id?: string;
6746
+ _local_seq?: string;
6747
+ _rev?: string;
6748
+ _revisions?: Revisions.Transport;
6749
+ _revs_info?: DocumentRevisionStatus[];
6750
+ /** Document.Document.Transport accepts additional properties. */
6751
+ [propName: string]: any;
6752
+ }
6332
6753
  }
6333
6754
  /** Schema for the result of a document modification. */
6334
- interface DocumentResult {
6755
+ class DocumentResult {
6335
6756
  /** Schema for a document ID. */
6336
6757
  id: string;
6337
6758
  /** Schema for a document revision identifier. */
@@ -6339,20 +6760,34 @@ declare namespace CloudantV1 {
6339
6760
  /** ok. */
6340
6761
  ok?: boolean;
6341
6762
  /** The cause of the error (if available). */
6342
- caused_by?: string;
6763
+ causedBy?: string;
6343
6764
  /** The name of the error. */
6344
6765
  error?: string;
6345
6766
  /** The reason the error occurred (if available). */
6346
6767
  reason?: string;
6768
+ static serialize(obj: any): DocumentResult.Transport;
6769
+ static deserialize(obj: any): DocumentResult;
6770
+ }
6771
+ namespace DocumentResult {
6772
+ interface Transport {
6773
+ id: string;
6774
+ rev?: string;
6775
+ ok?: boolean;
6776
+ caused_by?: string;
6777
+ error?: string;
6778
+ reason?: string;
6779
+ }
6347
6780
  }
6348
6781
  /** Schema for information about revisions and their status. */
6349
- interface DocumentRevisionStatus {
6782
+ class DocumentRevisionStatus {
6350
6783
  /** Schema for a document revision identifier. */
6351
6784
  rev: string;
6352
6785
  /** Status of the revision. May be one of: - `available`: Revision is available for retrieving with rev query
6353
6786
  * parameter - `missing`: Revision is not available - `deleted`: Revision belongs to deleted document.
6354
6787
  */
6355
6788
  status: DocumentRevisionStatus.Constants.Status | string;
6789
+ static serialize(obj: any): DocumentRevisionStatus.Transport;
6790
+ static deserialize(obj: any): DocumentRevisionStatus;
6356
6791
  }
6357
6792
  namespace DocumentRevisionStatus {
6358
6793
  namespace Constants {
@@ -6363,29 +6798,52 @@ declare namespace CloudantV1 {
6363
6798
  DELETED = "deleted"
6364
6799
  }
6365
6800
  }
6801
+ interface Transport {
6802
+ rev: string;
6803
+ status: string;
6804
+ }
6366
6805
  }
6367
6806
  /** Schema for document shard information. */
6368
- interface DocumentShardInfo {
6807
+ class DocumentShardInfo {
6369
6808
  /** List of nodes serving a replica of the shard. */
6370
6809
  nodes: string[];
6371
6810
  /** The shard range in which the document is stored. */
6372
6811
  range: string;
6812
+ static serialize(obj: any): DocumentShardInfo.Transport;
6813
+ static deserialize(obj: any): DocumentShardInfo;
6814
+ }
6815
+ namespace DocumentShardInfo {
6816
+ interface Transport {
6817
+ nodes: string[];
6818
+ range: string;
6819
+ }
6373
6820
  }
6374
6821
  /** Schema for find query execution statistics. */
6375
- interface ExecutionStats {
6822
+ class ExecutionStats {
6376
6823
  /** Time to execute the query. */
6377
- execution_time_ms: number;
6824
+ executionTimeMs: number;
6378
6825
  /** Number of results returned. */
6379
- results_returned: number;
6826
+ resultsReturned: number;
6380
6827
  /** Number of documents fetched from the index. */
6381
- total_docs_examined: number;
6828
+ totalDocsExamined: number;
6382
6829
  /** Number of rows scanned in the index. */
6383
- total_keys_examined: number;
6830
+ totalKeysExamined: number;
6384
6831
  /** Number of documents fetched from the primary index with the specified read quorum. */
6385
- total_quorum_docs_examined: number;
6832
+ totalQuorumDocsExamined: number;
6833
+ static serialize(obj: any): ExecutionStats.Transport;
6834
+ static deserialize(obj: any): ExecutionStats;
6835
+ }
6836
+ namespace ExecutionStats {
6837
+ interface Transport {
6838
+ execution_time_ms: number;
6839
+ results_returned: number;
6840
+ total_docs_examined: number;
6841
+ total_keys_examined: number;
6842
+ total_quorum_docs_examined: number;
6843
+ }
6386
6844
  }
6387
6845
  /** Schema for information about the index used for a find query. */
6388
- interface ExplainResult {
6846
+ class ExplainResult {
6389
6847
  /** When `true`, the query is answered using the index only and no documents are fetched. */
6390
6848
  covering: boolean;
6391
6849
  /** Name of database. */
@@ -6403,7 +6861,7 @@ declare namespace CloudantV1 {
6403
6861
  /** Options used for the request. */
6404
6862
  opts: ExplainResultOpts;
6405
6863
  /** Schema for any JSON type. */
6406
- partitioned?: any;
6864
+ partitioned?: any | null;
6407
6865
  /** JSON object describing criteria used to select documents. The selector specifies fields in the document, and
6408
6866
  * provides an expression to evaluate with the field content or other data.
6409
6867
  *
@@ -6435,21 +6893,37 @@ declare namespace CloudantV1 {
6435
6893
  selector: JsonObject;
6436
6894
  /** Skip parameter used. */
6437
6895
  skip: number;
6896
+ static serialize(obj: any): ExplainResult.Transport;
6897
+ static deserialize(obj: any): ExplainResult;
6898
+ }
6899
+ namespace ExplainResult {
6900
+ interface Transport {
6901
+ covering: boolean;
6902
+ dbname: string;
6903
+ fields: string[];
6904
+ index: IndexInformation.Transport;
6905
+ limit: number;
6906
+ mrargs?: ExplainResultMrArgs.Transport;
6907
+ opts: ExplainResultOpts.Transport;
6908
+ partitioned?: any;
6909
+ selector: JsonObject;
6910
+ skip: number;
6911
+ }
6438
6912
  }
6439
6913
  /** Arguments passed to the underlying view. */
6440
- interface ExplainResultMrArgs {
6914
+ class ExplainResultMrArgs {
6441
6915
  /** Schema for any JSON type. */
6442
- conflicts?: any;
6916
+ conflicts?: any | null;
6443
6917
  /** Direction parameter passed to the underlying view. */
6444
6918
  direction?: string;
6445
6919
  /** Schema for any JSON type. */
6446
- end_key?: any;
6920
+ endKey?: any | null;
6447
6921
  /** A parameter that specifies whether to include the full content of the documents in the response in the
6448
6922
  * underlying view.
6449
6923
  */
6450
- include_docs?: boolean;
6924
+ includeDocs?: boolean;
6451
6925
  /** Partition parameter passed to the underlying view. */
6452
- partition?: string;
6926
+ partition?: string | null;
6453
6927
  /** A parameter that specifies returning only documents that match any of the specified keys in the underlying
6454
6928
  * view.
6455
6929
  */
@@ -6459,11 +6933,13 @@ declare namespace CloudantV1 {
6459
6933
  */
6460
6934
  stable?: boolean;
6461
6935
  /** Schema for any JSON type. */
6462
- start_key?: any;
6936
+ startKey?: any | null;
6463
6937
  /** Schema for any JSON type. */
6464
- update?: any;
6938
+ update?: any | null;
6465
6939
  /** The type of the underlying view. */
6466
- view_type?: ExplainResultMrArgs.Constants.ViewType | string;
6940
+ viewType?: ExplainResultMrArgs.Constants.ViewType | string;
6941
+ static serialize(obj: any): ExplainResultMrArgs.Transport;
6942
+ static deserialize(obj: any): ExplainResultMrArgs;
6467
6943
  }
6468
6944
  namespace ExplainResultMrArgs {
6469
6945
  namespace Constants {
@@ -6473,15 +6949,27 @@ declare namespace CloudantV1 {
6473
6949
  REDUCE = "reduce"
6474
6950
  }
6475
6951
  }
6952
+ interface Transport {
6953
+ conflicts?: any;
6954
+ direction?: string;
6955
+ end_key?: any;
6956
+ include_docs?: boolean;
6957
+ partition?: string;
6958
+ reduce?: boolean;
6959
+ stable?: boolean;
6960
+ start_key?: any;
6961
+ update?: any;
6962
+ view_type?: string;
6963
+ }
6476
6964
  }
6477
6965
  /** Options used for the request. */
6478
- interface ExplainResultOpts {
6966
+ class ExplainResultOpts {
6479
6967
  /** Opaque bookmark token used when paginating results. */
6480
6968
  bookmark: string;
6481
6969
  /** Conflicts used in the request query. */
6482
6970
  conflicts: boolean;
6483
6971
  /** Execution statistics used in the request query. */
6484
- execution_stats: boolean;
6972
+ executionStats: boolean;
6485
6973
  /** JSON array that uses the field syntax. Use this parameter to specify which fields of a document must be
6486
6974
  * returned. If it is omitted or empty, the entire document is returned.
6487
6975
  */
@@ -6497,7 +6985,7 @@ declare namespace CloudantV1 {
6497
6985
  /** Skip used in the request query. */
6498
6986
  skip: number;
6499
6987
  /** Schema for any JSON type. */
6500
- sort: any;
6988
+ sort: any | null;
6501
6989
  /** Stable used in the request query. */
6502
6990
  stable: boolean;
6503
6991
  /** Deprecated: Stale used in the request query. */
@@ -6505,27 +6993,56 @@ declare namespace CloudantV1 {
6505
6993
  /** Update used in the request query. */
6506
6994
  update: boolean;
6507
6995
  /** Use index used in the request query. */
6508
- use_index: string[];
6996
+ useIndex: string[];
6997
+ static serialize(obj: any): ExplainResultOpts.Transport;
6998
+ static deserialize(obj: any): ExplainResultOpts;
6999
+ }
7000
+ namespace ExplainResultOpts {
7001
+ interface Transport {
7002
+ bookmark: string;
7003
+ conflicts: boolean;
7004
+ execution_stats: boolean;
7005
+ fields: string[];
7006
+ limit: number;
7007
+ partition: string;
7008
+ r: number;
7009
+ skip: number;
7010
+ sort: any;
7011
+ stable: boolean;
7012
+ stale: boolean;
7013
+ update: boolean;
7014
+ use_index: string[];
7015
+ }
6509
7016
  }
6510
7017
  /** Schema for the result of a query find operation. */
6511
- interface FindResult {
7018
+ class FindResult {
6512
7019
  /** Opaque bookmark token used when paginating results. */
6513
7020
  bookmark: string;
6514
7021
  /** Documents matching the selector. */
6515
7022
  docs: Document[];
6516
7023
  /** Schema for find query execution statistics. */
6517
- execution_stats?: ExecutionStats;
7024
+ executionStats?: ExecutionStats;
6518
7025
  /** warning. */
6519
7026
  warning?: string;
7027
+ static serialize(obj: any): FindResult.Transport;
7028
+ static deserialize(obj: any): FindResult;
7029
+ }
7030
+ namespace FindResult {
7031
+ interface Transport {
7032
+ bookmark: string;
7033
+ docs: Document[];
7034
+ execution_stats?: ExecutionStats.Transport;
7035
+ warning?: string;
7036
+ }
6520
7037
  }
6521
7038
  /** Schema for a `json` or `text` query index definition. Indexes of type `text` have additional configuration properties that do not apply to `json` indexes, these are: * `default_analyzer` - the default text analyzer to use * `default_field` - whether to index the text in all document fields and what analyzer to use for that purpose. */
6522
- interface IndexDefinition {
7039
+ class IndexDefinition {
6523
7040
  /** Schema for a full text search analyzer. */
6524
- default_analyzer?: Analyzer;
7041
+ defaultAnalyzer?: Analyzer;
6525
7042
  /** Schema for the text index default field configuration. The default field is used to index the text of all
6526
7043
  * fields within a document for use with the `$text` operator.
6527
7044
  */
6528
- default_field?: IndexTextOperatorDefaultField;
7045
+ defaultField?: IndexTextOperatorDefaultField;
6529
7046
  /** List of field objects to index. Nested fields are also allowed, e.g. `person.name`.
6530
7047
  *
6531
7048
  * For "json" type indexes each object is a mapping of field name to sort direction (asc or desc).
@@ -6540,7 +7057,7 @@ declare namespace CloudantV1 {
6540
7057
  * database are complex, or not completely under your control. As a result, it is difficult to estimate the impact
6541
7058
  * of the extra processing that is needed to determine and store the arrays lengths.
6542
7059
  */
6543
- index_array_lengths?: boolean;
7060
+ indexArrayLengths?: boolean;
6544
7061
  /** JSON object describing criteria used to select documents. The selector specifies fields in the document, and
6545
7062
  * provides an expression to evaluate with the field content or other data.
6546
7063
  *
@@ -6569,16 +7086,29 @@ declare namespace CloudantV1 {
6569
7086
  * For further reference see
6570
7087
  * [selector syntax](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-selector-syntax).
6571
7088
  */
6572
- partial_filter_selector?: JsonObject;
7089
+ partialFilterSelector?: JsonObject;
7090
+ static serialize(obj: any): IndexDefinition.Transport;
7091
+ static deserialize(obj: any): IndexDefinition;
7092
+ }
7093
+ namespace IndexDefinition {
7094
+ interface Transport {
7095
+ default_analyzer?: Analyzer.Transport;
7096
+ default_field?: IndexTextOperatorDefaultField.Transport;
7097
+ fields?: IndexField[];
7098
+ index_array_lengths?: boolean;
7099
+ partial_filter_selector?: JsonObject;
7100
+ }
6573
7101
  }
6574
7102
  /** Schema for indexed fields for use with declarative JSON query. */
6575
- interface IndexField {
7103
+ class IndexField {
6576
7104
  /** Name of the field. */
6577
7105
  name?: string;
6578
7106
  /** The type of the named field. */
6579
7107
  type?: IndexField.Constants.Type | string;
6580
7108
  /** IndexField accepts additional properties. */
6581
7109
  [propName: string]: any;
7110
+ static serialize(obj: any): IndexField.Transport;
7111
+ static deserialize(obj: any): IndexField;
6582
7112
  }
6583
7113
  namespace IndexField {
6584
7114
  namespace Constants {
@@ -6589,11 +7119,17 @@ declare namespace CloudantV1 {
6589
7119
  STRING = "string"
6590
7120
  }
6591
7121
  }
7122
+ interface Transport {
7123
+ name?: string;
7124
+ type?: string;
7125
+ /** IndexField.IndexField.Transport accepts additional properties. */
7126
+ [propName: string]: any;
7127
+ }
6592
7128
  }
6593
7129
  /** Schema for information about an index. */
6594
- interface IndexInformation {
7130
+ class IndexInformation {
6595
7131
  /** Design document ID including a `_design/` prefix. */
6596
- ddoc: string;
7132
+ ddoc: string | null;
6597
7133
  /** Schema for a `json` or `text` query index definition. Indexes of type `text` have additional configuration
6598
7134
  * properties that do not apply to `json` indexes, these are:
6599
7135
  * * `default_analyzer` - the default text analyzer to use * `default_field` - whether to index the text in all
@@ -6606,6 +7142,8 @@ declare namespace CloudantV1 {
6606
7142
  partitioned?: boolean;
6607
7143
  /** Schema for the type of an index. */
6608
7144
  type: IndexInformation.Constants.Type | string;
7145
+ static serialize(obj: any): IndexInformation.Transport;
7146
+ static deserialize(obj: any): IndexInformation;
6609
7147
  }
6610
7148
  namespace IndexInformation {
6611
7149
  namespace Constants {
@@ -6616,15 +7154,24 @@ declare namespace CloudantV1 {
6616
7154
  TEXT = "text"
6617
7155
  }
6618
7156
  }
7157
+ interface Transport {
7158
+ ddoc: string;
7159
+ def: IndexDefinition.Transport;
7160
+ name: string;
7161
+ partitioned?: boolean;
7162
+ type: string;
7163
+ }
6619
7164
  }
6620
7165
  /** Schema for the result of creating an index. */
6621
- interface IndexResult {
7166
+ class IndexResult {
6622
7167
  /** Id of the design document the index was created in. */
6623
7168
  id: string;
6624
7169
  /** Name of the index created. */
6625
7170
  name: string;
6626
7171
  /** Flag to show whether the index was created or one already exists. */
6627
7172
  result: IndexResult.Constants.Result | string;
7173
+ static serialize(obj: any): IndexResult.Transport;
7174
+ static deserialize(obj: any): IndexResult;
6628
7175
  }
6629
7176
  namespace IndexResult {
6630
7177
  namespace Constants {
@@ -6634,89 +7181,179 @@ declare namespace CloudantV1 {
6634
7181
  EXISTS = "exists"
6635
7182
  }
6636
7183
  }
7184
+ interface Transport {
7185
+ id: string;
7186
+ name: string;
7187
+ result: string;
7188
+ }
6637
7189
  }
6638
7190
  /** Schema for the text index default field configuration. The default field is used to index the text of all fields within a document for use with the `$text` operator. */
6639
- interface IndexTextOperatorDefaultField {
7191
+ class IndexTextOperatorDefaultField {
6640
7192
  /** Schema for a full text search analyzer. */
6641
7193
  analyzer?: Analyzer;
6642
7194
  /** Whether or not the default_field is enabled. */
6643
7195
  enabled?: boolean;
7196
+ static serialize(obj: any): IndexTextOperatorDefaultField.Transport;
7197
+ static deserialize(obj: any): IndexTextOperatorDefaultField;
7198
+ }
7199
+ namespace IndexTextOperatorDefaultField {
7200
+ interface Transport {
7201
+ analyzer?: Analyzer.Transport;
7202
+ enabled?: boolean;
7203
+ }
6644
7204
  }
6645
7205
  /** Schema for information about the indexes in a database. */
6646
- interface IndexesInformation {
7206
+ class IndexesInformation {
6647
7207
  /** Number of total rows. */
6648
- total_rows: number;
7208
+ totalRows: number | null;
6649
7209
  /** Indexes. */
6650
7210
  indexes: IndexInformation[];
7211
+ static serialize(obj: any): IndexesInformation.Transport;
7212
+ static deserialize(obj: any): IndexesInformation;
7213
+ }
7214
+ namespace IndexesInformation {
7215
+ interface Transport {
7216
+ total_rows: number;
7217
+ indexes: IndexInformation[];
7218
+ }
6651
7219
  }
6652
7220
  /** Schema for information about known nodes and cluster membership. */
6653
- interface MembershipInformation {
7221
+ class MembershipInformation {
6654
7222
  /** List of nodes this node knows about, including the ones that are part of the cluster. */
6655
- all_nodes: string[];
7223
+ allNodes: string[];
6656
7224
  /** All cluster nodes. */
6657
- cluster_nodes: string[];
7225
+ clusterNodes: string[];
7226
+ static serialize(obj: any): MembershipInformation.Transport;
7227
+ static deserialize(obj: any): MembershipInformation;
7228
+ }
7229
+ namespace MembershipInformation {
7230
+ interface Transport {
7231
+ all_nodes: string[];
7232
+ cluster_nodes: string[];
7233
+ }
6658
7234
  }
6659
7235
  /** Schema for an OK result. */
6660
- interface Ok {
7236
+ class Ok {
6661
7237
  /** ok. */
6662
7238
  ok?: boolean;
7239
+ static serialize(obj: any): Ok.Transport;
7240
+ static deserialize(obj: any): Ok;
7241
+ }
7242
+ namespace Ok {
7243
+ interface Transport {
7244
+ ok?: boolean;
7245
+ }
6663
7246
  }
6664
7247
  /** Schema for information about a database partition. */
6665
- interface PartitionInformation {
7248
+ class PartitionInformation {
6666
7249
  /** The name of the database. */
6667
- db_name: string;
7250
+ dbName: string;
6668
7251
  /** A count of the documents in the specified database partition. */
6669
- doc_count: number;
7252
+ docCount: number;
6670
7253
  /** Number of deleted documents. */
6671
- doc_del_count: number;
7254
+ docDelCount: number;
6672
7255
  /** The name of the partition in the database. */
6673
7256
  partition: string;
6674
7257
  /** Schema for information about the partition index count and limit in a database. */
6675
- partitioned_indexes?: PartitionInformationIndexes;
7258
+ partitionedIndexes?: PartitionInformationIndexes;
6676
7259
  /** The size of active and external data, in bytes. */
6677
7260
  sizes: PartitionInformationSizes;
7261
+ static serialize(obj: any): PartitionInformation.Transport;
7262
+ static deserialize(obj: any): PartitionInformation;
7263
+ }
7264
+ namespace PartitionInformation {
7265
+ interface Transport {
7266
+ db_name: string;
7267
+ doc_count: number;
7268
+ doc_del_count: number;
7269
+ partition: string;
7270
+ partitioned_indexes?: PartitionInformationIndexes.Transport;
7271
+ sizes: PartitionInformationSizes.Transport;
7272
+ }
6678
7273
  }
6679
7274
  /** Schema for information about the partition index count and limit in a database. */
6680
- interface PartitionInformationIndexes {
7275
+ class PartitionInformationIndexes {
6681
7276
  /** Total count of the partitioned indexes. */
6682
7277
  count?: number;
6683
7278
  /** The count breakdown of partitioned indexes. */
6684
7279
  indexes?: PartitionInformationIndexesIndexes;
6685
7280
  /** The partitioned index limit. */
6686
7281
  limit?: number;
7282
+ static serialize(obj: any): PartitionInformationIndexes.Transport;
7283
+ static deserialize(obj: any): PartitionInformationIndexes;
7284
+ }
7285
+ namespace PartitionInformationIndexes {
7286
+ interface Transport {
7287
+ count?: number;
7288
+ indexes?: PartitionInformationIndexesIndexes.Transport;
7289
+ limit?: number;
7290
+ }
6687
7291
  }
6688
7292
  /** The count breakdown of partitioned indexes. */
6689
- interface PartitionInformationIndexesIndexes {
7293
+ class PartitionInformationIndexesIndexes {
6690
7294
  /** Number of partitioned search indexes. */
6691
7295
  search?: number;
6692
7296
  /** Number of partitioned view indexes. */
6693
7297
  view?: number;
7298
+ static serialize(obj: any): PartitionInformationIndexesIndexes.Transport;
7299
+ static deserialize(obj: any): PartitionInformationIndexesIndexes;
7300
+ }
7301
+ namespace PartitionInformationIndexesIndexes {
7302
+ interface Transport {
7303
+ search?: number;
7304
+ view?: number;
7305
+ }
6694
7306
  }
6695
7307
  /** The size of active and external data, in bytes. */
6696
- interface PartitionInformationSizes {
7308
+ class PartitionInformationSizes {
6697
7309
  /** The size of live data inside the database, in bytes. */
6698
7310
  active?: number;
6699
7311
  /** The uncompressed size of database contents in bytes. */
6700
7312
  external?: number;
7313
+ static serialize(obj: any): PartitionInformationSizes.Transport;
7314
+ static deserialize(obj: any): PartitionInformationSizes;
7315
+ }
7316
+ namespace PartitionInformationSizes {
7317
+ interface Transport {
7318
+ active?: number;
7319
+ external?: number;
7320
+ }
6701
7321
  }
6702
7322
  /** Number of partitioned indexes by type. */
6703
- interface PartitionedIndexesDetailedInformation {
7323
+ class PartitionedIndexesDetailedInformation {
6704
7324
  /** Number of partitioned indexes of search type. */
6705
7325
  search?: number;
6706
7326
  /** Number of partitioned indexes of view type. */
6707
7327
  view?: number;
7328
+ static serialize(obj: any): PartitionedIndexesDetailedInformation.Transport;
7329
+ static deserialize(obj: any): PartitionedIndexesDetailedInformation;
7330
+ }
7331
+ namespace PartitionedIndexesDetailedInformation {
7332
+ interface Transport {
7333
+ search?: number;
7334
+ view?: number;
7335
+ }
6708
7336
  }
6709
7337
  /** Information about database's partitioned indexes. */
6710
- interface PartitionedIndexesInformation {
7338
+ class PartitionedIndexesInformation {
6711
7339
  /** Total number of partitioned indexes in the database. */
6712
7340
  count?: number;
6713
7341
  /** Number of partitioned indexes by type. */
6714
7342
  indexes?: PartitionedIndexesDetailedInformation;
6715
7343
  /** Maximum allowed number of partitioned indexes in the database. */
6716
7344
  limit?: number;
7345
+ static serialize(obj: any): PartitionedIndexesInformation.Transport;
7346
+ static deserialize(obj: any): PartitionedIndexesInformation;
7347
+ }
7348
+ namespace PartitionedIndexesInformation {
7349
+ interface Transport {
7350
+ count?: number;
7351
+ indexes?: PartitionedIndexesDetailedInformation.Transport;
7352
+ limit?: number;
7353
+ }
6717
7354
  }
6718
7355
  /** Request parameters to use during target database creation. */
6719
- interface ReplicationCreateTargetParameters {
7356
+ class ReplicationCreateTargetParameters {
6720
7357
  /** Schema for the number of replicas of a database in a cluster. The cluster is using the default value and it
6721
7358
  * cannot be changed by the user.
6722
7359
  */
@@ -6725,39 +7362,82 @@ declare namespace CloudantV1 {
6725
7362
  partitioned?: boolean;
6726
7363
  /** Schema for the number of shards in a database. Each shard is a partition of the hash value range. */
6727
7364
  q?: number;
7365
+ static serialize(obj: any): ReplicationCreateTargetParameters.Transport;
7366
+ static deserialize(obj: any): ReplicationCreateTargetParameters;
7367
+ }
7368
+ namespace ReplicationCreateTargetParameters {
7369
+ interface Transport {
7370
+ n?: number;
7371
+ partitioned?: boolean;
7372
+ q?: number;
7373
+ }
6728
7374
  }
6729
7375
  /** Schema for a replication source or target database. */
6730
- interface ReplicationDatabase {
7376
+ class ReplicationDatabase {
6731
7377
  /** Schema for replication source or target database authentication. */
6732
7378
  auth?: ReplicationDatabaseAuth;
6733
7379
  /** Replication request headers. */
6734
7380
  headers?: JsonObject;
6735
7381
  /** Replication database URL. */
6736
7382
  url: string;
7383
+ static serialize(obj: any): ReplicationDatabase.Transport;
7384
+ static deserialize(obj: any): ReplicationDatabase;
7385
+ }
7386
+ namespace ReplicationDatabase {
7387
+ interface Transport {
7388
+ auth?: ReplicationDatabaseAuth.Transport;
7389
+ headers?: JsonObject;
7390
+ url: string;
7391
+ }
6737
7392
  }
6738
7393
  /** Schema for replication source or target database authentication. */
6739
- interface ReplicationDatabaseAuth {
7394
+ class ReplicationDatabaseAuth {
6740
7395
  /** Schema for basic authentication of replication source or target database. */
6741
7396
  basic?: ReplicationDatabaseAuthBasic;
6742
7397
  /** Schema for an IAM API key for replication database authentication. */
6743
7398
  iam?: ReplicationDatabaseAuthIam;
7399
+ static serialize(obj: any): ReplicationDatabaseAuth.Transport;
7400
+ static deserialize(obj: any): ReplicationDatabaseAuth;
7401
+ }
7402
+ namespace ReplicationDatabaseAuth {
7403
+ interface Transport {
7404
+ basic?: ReplicationDatabaseAuthBasic.Transport;
7405
+ iam?: ReplicationDatabaseAuthIam.Transport;
7406
+ }
6744
7407
  }
6745
7408
  /** Schema for basic authentication of replication source or target database. */
6746
- interface ReplicationDatabaseAuthBasic {
7409
+ class ReplicationDatabaseAuthBasic {
6747
7410
  /** The password associated with the username. */
6748
7411
  password: string;
6749
7412
  /** The username. */
6750
7413
  username: string;
7414
+ static serialize(obj: any): ReplicationDatabaseAuthBasic.Transport;
7415
+ static deserialize(obj: any): ReplicationDatabaseAuthBasic;
7416
+ }
7417
+ namespace ReplicationDatabaseAuthBasic {
7418
+ interface Transport {
7419
+ password: string;
7420
+ username: string;
7421
+ }
6751
7422
  }
6752
7423
  /** Schema for an IAM API key for replication database authentication. */
6753
- interface ReplicationDatabaseAuthIam {
7424
+ class ReplicationDatabaseAuthIam {
6754
7425
  /** IAM API key. */
6755
- api_key: string;
7426
+ apiKey: string;
7427
+ static serialize(obj: any): ReplicationDatabaseAuthIam.Transport;
7428
+ static deserialize(obj: any): ReplicationDatabaseAuthIam;
7429
+ }
7430
+ namespace ReplicationDatabaseAuthIam {
7431
+ interface Transport {
7432
+ api_key: string;
7433
+ }
6756
7434
  }
6757
7435
  /** Schema for a replication document. Note that `selector`, `doc_ids`, and `filter` are incompatible with each other. */
6758
- interface ReplicationDocument {
7436
+ class ReplicationDocument {
6759
7437
  /** Schema for a map of attachment name to attachment metadata. */
6760
- _attachments?: JsonObject;
7438
+ _attachments?: {
7439
+ [key: string]: Attachment;
7440
+ };
6761
7441
  /** Schema for a list of document revision identifiers. */
6762
7442
  _conflicts?: string[];
6763
7443
  /** Deletion flag. Available if document was removed. */
@@ -6777,32 +7457,32 @@ declare namespace CloudantV1 {
6777
7457
  /** Cancels the replication. */
6778
7458
  cancel?: boolean;
6779
7459
  /** Defines replication checkpoint interval in milliseconds. */
6780
- checkpoint_interval?: number;
7460
+ checkpointInterval?: number;
6781
7461
  /** HTTP connection timeout per replication. Even for very fast/reliable networks it might need to be increased
6782
7462
  * if a remote database is too busy.
6783
7463
  */
6784
- connection_timeout?: number;
7464
+ connectionTimeout?: number;
6785
7465
  /** Configure the replication to be continuous. */
6786
7466
  continuous?: boolean;
6787
7467
  /** Creates the target database. Requires administrator privileges on target server. */
6788
- create_target?: boolean;
7468
+ createTarget?: boolean;
6789
7469
  /** Request parameters to use during target database creation. */
6790
- create_target_params?: ReplicationCreateTargetParameters;
7470
+ createTargetParams?: ReplicationCreateTargetParameters;
6791
7471
  /** Schema for a list of document IDs. */
6792
- doc_ids?: string[];
7472
+ docIds?: string[];
6793
7473
  /** The name of a filter function which is defined in a design document in the source database in
6794
7474
  * {ddoc_id}/{filter} format. It determines which documents get replicated. Using the selector option provides
6795
7475
  * performance benefits when compared with using the filter option. Use the selector option when possible.
6796
7476
  */
6797
7477
  filter?: string;
6798
7478
  /** Maximum number of HTTP connections per replication. */
6799
- http_connections?: number;
7479
+ httpConnections?: number;
6800
7480
  /** Schema for a map of string key value pairs, such as query parameters. */
6801
- query_params?: JsonObject;
7481
+ queryParams?: JsonObject;
6802
7482
  /** Number of times a replication request is retried. The requests are retried with a doubling exponential
6803
7483
  * backoff starting at 0.25 seconds, with a cap at 5 minutes.
6804
7484
  */
6805
- retries_per_request?: number;
7485
+ retriesPerRequest?: number;
6806
7486
  /** JSON object describing criteria used to select documents. The selector specifies fields in the document, and
6807
7487
  * provides an expression to evaluate with the field content or other data.
6808
7488
  *
@@ -6833,9 +7513,9 @@ declare namespace CloudantV1 {
6833
7513
  */
6834
7514
  selector?: JsonObject;
6835
7515
  /** Start the replication at a specific sequence value. */
6836
- since_seq?: string;
7516
+ sinceSeq?: string;
6837
7517
  /** Replication socket options. */
6838
- socket_options?: string;
7518
+ socketOptions?: string;
6839
7519
  /** Schema for a replication source or target database. */
6840
7520
  source: ReplicationDatabase;
6841
7521
  /** Deprecated: This setting is forbidden in IBM Cloudant replication documents. This setting may be used with
@@ -6844,7 +7524,7 @@ declare namespace CloudantV1 {
6844
7524
  * Address of a (http or socks5 protocol) proxy server through which replication with the source database should
6845
7525
  * occur.
6846
7526
  */
6847
- source_proxy?: string;
7527
+ sourceProxy?: string | null;
6848
7528
  /** Schema for a replication source or target database. */
6849
7529
  target: ReplicationDatabase;
6850
7530
  /** Deprecated: This setting is forbidden in IBM Cloudant replication documents. This setting may be used with
@@ -6853,73 +7533,140 @@ declare namespace CloudantV1 {
6853
7533
  * Address of a (http or socks5 protocol) proxy server through which replication with the target database should
6854
7534
  * occur.
6855
7535
  */
6856
- target_proxy?: string;
7536
+ targetProxy?: string | null;
6857
7537
  /** Specify whether to use _bulk_get for fetching documents from the source. If unset, the server configured
6858
7538
  * default will be used.
6859
7539
  */
6860
- use_bulk_get?: boolean;
7540
+ useBulkGet?: boolean;
6861
7541
  /** Specify if checkpoints should be saved during replication. Using checkpoints means a replication can be
6862
7542
  * efficiently resumed.
6863
7543
  */
6864
- use_checkpoints?: boolean;
7544
+ useCheckpoints?: boolean;
6865
7545
  /** Schema for the user context of a session. */
6866
- user_ctx?: UserContext;
7546
+ userCtx?: UserContext;
6867
7547
  /** Replicate only the winning revisions. Replication with this mode discards conflicting revisions. Replication
6868
7548
  * IDs and checkpoints generated by this mode are different to those generated by default, so it is possible to
6869
7549
  * first replicate the winning revisions then later backfill remaining revisions with a regular replication job.
6870
7550
  */
6871
- winning_revs_only?: boolean;
7551
+ winningRevsOnly?: boolean;
6872
7552
  /** Controls how many documents are processed. After each batch a checkpoint is written so this controls how
6873
7553
  * frequently checkpointing occurs.
6874
7554
  */
6875
- worker_batch_size?: number;
7555
+ workerBatchSize?: number;
6876
7556
  /** Controls how many separate processes will read from the changes manager and write to the target. A higher
6877
7557
  * number can improve throughput.
6878
7558
  */
6879
- worker_processes?: number;
7559
+ workerProcesses?: number;
6880
7560
  /** ReplicationDocument accepts additional properties. */
6881
7561
  [propName: string]: any;
7562
+ static serialize(obj: any): ReplicationDocument.Transport;
7563
+ static deserialize(obj: any): ReplicationDocument;
7564
+ }
7565
+ namespace ReplicationDocument {
7566
+ interface Transport {
7567
+ _attachments?: {
7568
+ [key: string]: Attachment.Transport;
7569
+ };
7570
+ _conflicts?: string[];
7571
+ _deleted?: boolean;
7572
+ _deleted_conflicts?: string[];
7573
+ _id?: string;
7574
+ _local_seq?: string;
7575
+ _rev?: string;
7576
+ _revisions?: Revisions.Transport;
7577
+ _revs_info?: DocumentRevisionStatus[];
7578
+ cancel?: boolean;
7579
+ checkpoint_interval?: number;
7580
+ connection_timeout?: number;
7581
+ continuous?: boolean;
7582
+ create_target?: boolean;
7583
+ create_target_params?: ReplicationCreateTargetParameters.Transport;
7584
+ doc_ids?: string[];
7585
+ filter?: string;
7586
+ http_connections?: number;
7587
+ query_params?: JsonObject;
7588
+ retries_per_request?: number;
7589
+ selector?: JsonObject;
7590
+ since_seq?: string;
7591
+ socket_options?: string;
7592
+ source: ReplicationDatabase.Transport;
7593
+ source_proxy?: string;
7594
+ target: ReplicationDatabase.Transport;
7595
+ target_proxy?: string;
7596
+ use_bulk_get?: boolean;
7597
+ use_checkpoints?: boolean;
7598
+ user_ctx?: UserContext.Transport;
7599
+ winning_revs_only?: boolean;
7600
+ worker_batch_size?: number;
7601
+ worker_processes?: number;
7602
+ /** ReplicationDocument.ReplicationDocument.Transport accepts additional properties. */
7603
+ [propName: string]: any;
7604
+ }
6882
7605
  }
6883
7606
  /** Schema for list of revision information. */
6884
- interface Revisions {
7607
+ class Revisions {
6885
7608
  /** Array of valid revision IDs, in reverse order (latest first). */
6886
7609
  ids: string[];
6887
7610
  /** Prefix number for the latest revision. */
6888
7611
  start: number;
7612
+ static serialize(obj: any): Revisions.Transport;
7613
+ static deserialize(obj: any): Revisions;
7614
+ }
7615
+ namespace Revisions {
7616
+ interface Transport {
7617
+ ids: string[];
7618
+ start: number;
7619
+ }
6889
7620
  }
6890
7621
  /** Schema for information about missing revs and possible ancestors. */
6891
- interface RevsDiff {
7622
+ class RevsDiff {
6892
7623
  /** List of missing revisions. */
6893
7624
  missing?: string[];
6894
7625
  /** List of possible ancestor revisions. */
6895
- possible_ancestors?: string[];
7626
+ possibleAncestors?: string[];
7627
+ static serialize(obj: any): RevsDiff.Transport;
7628
+ static deserialize(obj: any): RevsDiff;
7629
+ }
7630
+ namespace RevsDiff {
7631
+ interface Transport {
7632
+ missing?: string[];
7633
+ possible_ancestors?: string[];
7634
+ }
6896
7635
  }
6897
7636
  /** Schema for a listing of replication scheduler documents. */
6898
- interface SchedulerDocsResult {
7637
+ class SchedulerDocsResult {
6899
7638
  /** Number of total rows. */
6900
- total_rows: number;
7639
+ totalRows: number | null;
6901
7640
  /** Array of replication scheduler doc objects. */
6902
7641
  docs: SchedulerDocument[];
7642
+ static serialize(obj: any): SchedulerDocsResult.Transport;
7643
+ static deserialize(obj: any): SchedulerDocsResult;
7644
+ }
7645
+ namespace SchedulerDocsResult {
7646
+ interface Transport {
7647
+ total_rows: number;
7648
+ docs: SchedulerDocument[];
7649
+ }
6903
7650
  }
6904
7651
  /** Schema for a replication scheduler document. */
6905
- interface SchedulerDocument {
7652
+ class SchedulerDocument {
6906
7653
  /** Database where replication document came from. */
6907
7654
  database: string;
6908
7655
  /** Replication document ID. */
6909
- doc_id: string;
7656
+ docId: string;
6910
7657
  /** Consecutive errors count. Indicates how many times in a row this replication has crashed. Replication will
6911
7658
  * be retried with an exponential backoff based on this number. As soon as the replication succeeds this count is
6912
7659
  * reset to 0. To can be used to get an idea why a particular replication is not making progress.
6913
7660
  */
6914
- error_count: number;
7661
+ errorCount: number;
6915
7662
  /** Replication ID, or null if state is completed or failed. */
6916
- id: string;
7663
+ id: string | null;
6917
7664
  /** Schema for scheduler document information. A JSON object that may contain additional information about the
6918
7665
  * state. For error states this will contain an error field and string value.
6919
7666
  */
6920
- info: SchedulerInfo;
7667
+ info: SchedulerInfo | null;
6921
7668
  /** Timestamp of last state update. */
6922
- last_updated: string;
7669
+ lastUpdated: string;
6923
7670
  /** Cluster node where the job is running. */
6924
7671
  node?: string;
6925
7672
  /** Replication source. */
@@ -6928,9 +7675,9 @@ declare namespace CloudantV1 {
6928
7675
  *
6929
7676
  * Address of the (http or socks5 protocol) proxy server through which replication with the source database occurs.
6930
7677
  */
6931
- source_proxy?: string;
7678
+ sourceProxy?: string | null;
6932
7679
  /** Timestamp of when the replication was started. */
6933
- start_time: string;
7680
+ startTime: string;
6934
7681
  /** Schema for replication state. */
6935
7682
  state: SchedulerDocument.Constants.State | string;
6936
7683
  /** Replication target. */
@@ -6939,7 +7686,9 @@ declare namespace CloudantV1 {
6939
7686
  *
6940
7687
  * Address of the (http or socks5 protocol) proxy server through which replication with the target database occurs.
6941
7688
  */
6942
- target_proxy?: string;
7689
+ targetProxy?: string | null;
7690
+ static serialize(obj: any): SchedulerDocument.Transport;
7691
+ static deserialize(obj: any): SchedulerDocument;
6943
7692
  }
6944
7693
  namespace SchedulerDocument {
6945
7694
  namespace Constants {
@@ -6954,36 +7703,67 @@ declare namespace CloudantV1 {
6954
7703
  FAILED = "failed"
6955
7704
  }
6956
7705
  }
7706
+ interface Transport {
7707
+ database: string;
7708
+ doc_id: string;
7709
+ error_count: number;
7710
+ id: string;
7711
+ info: SchedulerInfo.Transport;
7712
+ last_updated: string;
7713
+ node?: string;
7714
+ source?: string;
7715
+ source_proxy?: string;
7716
+ start_time: string;
7717
+ state: string;
7718
+ target?: string;
7719
+ target_proxy?: string;
7720
+ }
6957
7721
  }
6958
7722
  /** Schema for scheduler document information. A JSON object that may contain additional information about the state. For error states this will contain an error field and string value. */
6959
- interface SchedulerInfo {
7723
+ class SchedulerInfo {
6960
7724
  /** The count of changes not yet replicated. */
6961
- changes_pending?: number;
7725
+ changesPending?: number | null;
6962
7726
  /** The source sequence id which was last successfully replicated. */
6963
- checkpointed_source_seq?: string;
7727
+ checkpointedSourceSeq?: string;
6964
7728
  /** The count of docs which failed to be written to the target. */
6965
- doc_write_failures?: number;
7729
+ docWriteFailures?: number;
6966
7730
  /** The count of docs which have been read from the source. */
6967
- docs_read?: number;
7731
+ docsRead?: number;
6968
7732
  /** The count of docs which have been written to the target. */
6969
- docs_written?: number;
7733
+ docsWritten?: number;
6970
7734
  /** Replication error message. */
6971
7735
  error?: string;
6972
7736
  /** The count of revisions which were found on the source, but missing from the target. */
6973
- missing_revisions_found?: number;
7737
+ missingRevisionsFound?: number;
6974
7738
  /** The count of revisions which have been checked since this replication began. */
6975
- revisions_checked?: number;
7739
+ revisionsChecked?: number;
6976
7740
  /** The last sequence number obtained from the source database changes feed. */
6977
- source_seq?: string;
7741
+ sourceSeq?: string;
6978
7742
  /** The last sequence number processed by the replicator. */
6979
- through_seq?: string;
7743
+ throughSeq?: string;
7744
+ static serialize(obj: any): SchedulerInfo.Transport;
7745
+ static deserialize(obj: any): SchedulerInfo;
7746
+ }
7747
+ namespace SchedulerInfo {
7748
+ interface Transport {
7749
+ changes_pending?: number;
7750
+ checkpointed_source_seq?: string;
7751
+ doc_write_failures?: number;
7752
+ docs_read?: number;
7753
+ docs_written?: number;
7754
+ error?: string;
7755
+ missing_revisions_found?: number;
7756
+ revisions_checked?: number;
7757
+ source_seq?: string;
7758
+ through_seq?: string;
7759
+ }
6980
7760
  }
6981
7761
  /** Schema for a replication scheduler job. */
6982
- interface SchedulerJob {
7762
+ class SchedulerJob {
6983
7763
  /** Replication document database. */
6984
7764
  database: string;
6985
7765
  /** Replication document ID. */
6986
- doc_id: string;
7766
+ docId: string;
6987
7767
  /** Timestamped history of events as a list of objects. */
6988
7768
  history: SchedulerJobEvent[];
6989
7769
  /** Schema for a replication job id. */
@@ -6991,43 +7771,84 @@ declare namespace CloudantV1 {
6991
7771
  /** Schema for scheduler document information. A JSON object that may contain additional information about the
6992
7772
  * state. For error states this will contain an error field and string value.
6993
7773
  */
6994
- info: SchedulerInfo;
7774
+ info: SchedulerInfo | null;
6995
7775
  /** Cluster node where the job is running. */
6996
7776
  node: string;
6997
7777
  /** Replication process ID. */
6998
- pid: string;
7778
+ pid: string | null;
6999
7779
  /** Replication source. */
7000
7780
  source: string;
7001
7781
  /** Timestamp of when the replication was started. */
7002
- start_time: string;
7782
+ startTime: string;
7003
7783
  /** Replication target. */
7004
7784
  target: string;
7005
7785
  /** Name of user running replication. */
7006
- user: string;
7786
+ user: string | null;
7787
+ static serialize(obj: any): SchedulerJob.Transport;
7788
+ static deserialize(obj: any): SchedulerJob;
7789
+ }
7790
+ namespace SchedulerJob {
7791
+ interface Transport {
7792
+ database: string;
7793
+ doc_id: string;
7794
+ history: SchedulerJobEvent[];
7795
+ id: string;
7796
+ info: SchedulerInfo.Transport;
7797
+ node: string;
7798
+ pid: string;
7799
+ source: string;
7800
+ start_time: string;
7801
+ target: string;
7802
+ user: string;
7803
+ }
7007
7804
  }
7008
7805
  /** Schema for a replication scheduler job event. */
7009
- interface SchedulerJobEvent {
7806
+ class SchedulerJobEvent {
7010
7807
  /** Reason for current state of event. */
7011
7808
  reason?: string;
7012
7809
  /** Timestamp of the event. */
7013
7810
  timestamp: string;
7014
7811
  /** Type of the event. */
7015
7812
  type: string;
7813
+ static serialize(obj: any): SchedulerJobEvent.Transport;
7814
+ static deserialize(obj: any): SchedulerJobEvent;
7815
+ }
7816
+ namespace SchedulerJobEvent {
7817
+ interface Transport {
7818
+ reason?: string;
7819
+ timestamp: string;
7820
+ type: string;
7821
+ }
7016
7822
  }
7017
7823
  /** Schema for a listing of replication scheduler jobs. */
7018
- interface SchedulerJobsResult {
7824
+ class SchedulerJobsResult {
7019
7825
  /** Number of total rows. */
7020
- total_rows: number;
7826
+ totalRows: number | null;
7021
7827
  /** Array of replication job objects. */
7022
7828
  jobs: SchedulerJob[];
7829
+ static serialize(obj: any): SchedulerJobsResult.Transport;
7830
+ static deserialize(obj: any): SchedulerJobsResult;
7831
+ }
7832
+ namespace SchedulerJobsResult {
7833
+ interface Transport {
7834
+ total_rows: number;
7835
+ jobs: SchedulerJob[];
7836
+ }
7023
7837
  }
7024
7838
  /** Schema for the output of testing search analyzer tokenization. */
7025
- interface SearchAnalyzeResult {
7839
+ class SearchAnalyzeResult {
7026
7840
  /** tokens. */
7027
7841
  tokens: string[];
7842
+ static serialize(obj: any): SearchAnalyzeResult.Transport;
7843
+ static deserialize(obj: any): SearchAnalyzeResult;
7844
+ }
7845
+ namespace SearchAnalyzeResult {
7846
+ interface Transport {
7847
+ tokens: string[];
7848
+ }
7028
7849
  }
7029
7850
  /** Schema for a search index definition. */
7030
- interface SearchIndexDefinition {
7851
+ class SearchIndexDefinition {
7031
7852
  /** Schema for a search analyzer configuration. */
7032
7853
  analyzer?: AnalyzerConfiguration;
7033
7854
  /** String form of a JavaScript function that is called for each document in the database. The function takes
@@ -7051,67 +7872,136 @@ declare namespace CloudantV1 {
7051
7872
  * in the search result; otherwise, the value is not returned.
7052
7873
  */
7053
7874
  index: string;
7875
+ static serialize(obj: any): SearchIndexDefinition.Transport;
7876
+ static deserialize(obj: any): SearchIndexDefinition;
7877
+ }
7878
+ namespace SearchIndexDefinition {
7879
+ interface Transport {
7880
+ analyzer?: AnalyzerConfiguration.Transport;
7881
+ index: string;
7882
+ }
7054
7883
  }
7055
7884
  /** Schema for metadata information about a search index. */
7056
- interface SearchIndexInfo {
7885
+ class SearchIndexInfo {
7057
7886
  /** The committed sequence identifier. */
7058
- committed_seq: number;
7887
+ committedSeq: number;
7059
7888
  /** The size of the search index on disk. */
7060
- disk_size: number;
7889
+ diskSize: number;
7061
7890
  /** The count of the number of indexed documents. */
7062
- doc_count: number;
7891
+ docCount: number;
7063
7892
  /** The number of deleted documents. */
7064
- doc_del_count: number;
7893
+ docDelCount: number;
7065
7894
  /** The pending sequence identifier. */
7066
- pending_seq: number;
7895
+ pendingSeq: number;
7067
7896
  /** Unique signature of the search index. */
7068
7897
  signature: string;
7898
+ static serialize(obj: any): SearchIndexInfo.Transport;
7899
+ static deserialize(obj: any): SearchIndexInfo;
7900
+ }
7901
+ namespace SearchIndexInfo {
7902
+ interface Transport {
7903
+ committed_seq: number;
7904
+ disk_size: number;
7905
+ doc_count: number;
7906
+ doc_del_count: number;
7907
+ pending_seq: number;
7908
+ signature: string;
7909
+ }
7069
7910
  }
7070
7911
  /** Schema for search index information. */
7071
- interface SearchInfoResult {
7912
+ class SearchInfoResult {
7072
7913
  /** The name of the search index prefixed by the design document ID where the index is stored. */
7073
7914
  name: string;
7074
7915
  /** Schema for metadata information about a search index. */
7075
- search_index: SearchIndexInfo;
7916
+ searchIndex: SearchIndexInfo;
7917
+ static serialize(obj: any): SearchInfoResult.Transport;
7918
+ static deserialize(obj: any): SearchInfoResult;
7919
+ }
7920
+ namespace SearchInfoResult {
7921
+ interface Transport {
7922
+ name: string;
7923
+ search_index: SearchIndexInfo.Transport;
7924
+ }
7076
7925
  }
7077
7926
  /** Schema for the result of a query search operation. */
7078
- interface SearchResult {
7927
+ class SearchResult {
7079
7928
  /** Number of total rows. */
7080
- total_rows: number;
7929
+ totalRows: number | null;
7081
7930
  /** Opaque bookmark token used when paginating results. */
7082
7931
  bookmark?: string;
7083
7932
  /** Grouped search matches. */
7084
7933
  by?: string;
7085
7934
  /** The counts facet syntax returns the number of query results for each unique value of each named field. */
7086
- counts?: JsonObject;
7935
+ counts?: {
7936
+ [key: string]: JsonObject;
7937
+ };
7087
7938
  /** The range facet syntax reuses the standard Lucene syntax for ranges to return counts of results that fit
7088
7939
  * into each specified category.
7089
7940
  */
7090
- ranges?: JsonObject;
7941
+ ranges?: {
7942
+ [key: string]: JsonObject;
7943
+ };
7091
7944
  /** Array of row objects. */
7092
7945
  rows?: SearchResultRow[];
7093
7946
  /** Array of grouped search matches. */
7094
7947
  groups?: SearchResultProperties[];
7948
+ static serialize(obj: any): SearchResult.Transport;
7949
+ static deserialize(obj: any): SearchResult;
7950
+ }
7951
+ namespace SearchResult {
7952
+ interface Transport {
7953
+ total_rows: number;
7954
+ bookmark?: string;
7955
+ by?: string;
7956
+ counts?: {
7957
+ [key: string]: JsonObject;
7958
+ };
7959
+ ranges?: {
7960
+ [key: string]: JsonObject;
7961
+ };
7962
+ rows?: SearchResultRow[];
7963
+ groups?: SearchResultProperties[];
7964
+ }
7095
7965
  }
7096
7966
  /** Schema for the result of a query search operation. */
7097
- interface SearchResultProperties {
7967
+ class SearchResultProperties {
7098
7968
  /** Number of total rows. */
7099
- total_rows: number;
7969
+ totalRows: number | null;
7100
7970
  /** Opaque bookmark token used when paginating results. */
7101
7971
  bookmark?: string;
7102
7972
  /** Grouped search matches. */
7103
7973
  by?: string;
7104
7974
  /** The counts facet syntax returns the number of query results for each unique value of each named field. */
7105
- counts?: JsonObject;
7975
+ counts?: {
7976
+ [key: string]: JsonObject;
7977
+ };
7106
7978
  /** The range facet syntax reuses the standard Lucene syntax for ranges to return counts of results that fit
7107
7979
  * into each specified category.
7108
7980
  */
7109
- ranges?: JsonObject;
7981
+ ranges?: {
7982
+ [key: string]: JsonObject;
7983
+ };
7110
7984
  /** Array of row objects. */
7111
7985
  rows?: SearchResultRow[];
7986
+ static serialize(obj: any): SearchResultProperties.Transport;
7987
+ static deserialize(obj: any): SearchResultProperties;
7988
+ }
7989
+ namespace SearchResultProperties {
7990
+ interface Transport {
7991
+ total_rows: number;
7992
+ bookmark?: string;
7993
+ by?: string;
7994
+ counts?: {
7995
+ [key: string]: JsonObject;
7996
+ };
7997
+ ranges?: {
7998
+ [key: string]: JsonObject;
7999
+ };
8000
+ rows?: SearchResultRow[];
8001
+ }
7112
8002
  }
7113
8003
  /** Schema for a row of the result of a query search operation. */
7114
- interface SearchResultRow {
8004
+ class SearchResultRow {
7115
8005
  /** Schema for a document. */
7116
8006
  doc?: Document;
7117
8007
  /** Schema for the fields returned by a query search operation, a map of field name to value. */
@@ -7122,9 +8012,19 @@ declare namespace CloudantV1 {
7122
8012
  highlights?: JsonObject;
7123
8013
  /** Schema for a document ID. */
7124
8014
  id: string;
8015
+ static serialize(obj: any): SearchResultRow.Transport;
8016
+ static deserialize(obj: any): SearchResultRow;
8017
+ }
8018
+ namespace SearchResultRow {
8019
+ interface Transport {
8020
+ doc?: Document.Transport;
8021
+ fields: JsonObject;
8022
+ highlights?: JsonObject;
8023
+ id: string;
8024
+ }
7125
8025
  }
7126
8026
  /** Schema for a security document. */
7127
- interface Security {
8027
+ class Security {
7128
8028
  /** Schema for names and roles to map to a database permission. */
7129
8029
  admins?: SecurityObject;
7130
8030
  /** Schema for names and roles to map to a database permission. */
@@ -7132,17 +8032,35 @@ declare namespace CloudantV1 {
7132
8032
  /** Database permissions for Cloudant users and/or API keys. */
7133
8033
  cloudant?: JsonObject;
7134
8034
  /** Manage permissions using the `_users` database only. */
7135
- couchdb_auth_only?: boolean;
8035
+ couchdbAuthOnly?: boolean;
8036
+ static serialize(obj: any): Security.Transport;
8037
+ static deserialize(obj: any): Security;
8038
+ }
8039
+ namespace Security {
8040
+ interface Transport {
8041
+ admins?: SecurityObject.Transport;
8042
+ members?: SecurityObject.Transport;
8043
+ cloudant?: JsonObject;
8044
+ couchdb_auth_only?: boolean;
8045
+ }
7136
8046
  }
7137
8047
  /** Schema for names and roles to map to a database permission. */
7138
- interface SecurityObject {
8048
+ class SecurityObject {
7139
8049
  /** List of usernames. */
7140
8050
  names?: string[];
7141
8051
  /** List of roles. */
7142
8052
  roles?: string[];
8053
+ static serialize(obj: any): SecurityObject.Transport;
8054
+ static deserialize(obj: any): SecurityObject;
8055
+ }
8056
+ namespace SecurityObject {
8057
+ interface Transport {
8058
+ names?: string[];
8059
+ roles?: string[];
8060
+ }
7143
8061
  }
7144
8062
  /** Schema for information about the server instance. */
7145
- interface ServerInformation {
8063
+ class ServerInformation {
7146
8064
  /** Welcome message. */
7147
8065
  couchdb: string;
7148
8066
  /** List of enabled optional features. */
@@ -7152,42 +8070,87 @@ declare namespace CloudantV1 {
7152
8070
  /** Apache CouchDB version. */
7153
8071
  version: string;
7154
8072
  /** List of feature flags. */
7155
- features_flags: string[];
8073
+ featuresFlags: string[];
8074
+ static serialize(obj: any): ServerInformation.Transport;
8075
+ static deserialize(obj: any): ServerInformation;
8076
+ }
8077
+ namespace ServerInformation {
8078
+ interface Transport {
8079
+ couchdb: string;
8080
+ features: string[];
8081
+ vendor: ServerVendor.Transport;
8082
+ version: string;
8083
+ features_flags: string[];
8084
+ }
7156
8085
  }
7157
8086
  /** Schema for server vendor information. */
7158
- interface ServerVendor {
8087
+ class ServerVendor {
7159
8088
  /** Vendor name. */
7160
8089
  name: string;
7161
8090
  /** Vendor variant. */
7162
8091
  variant?: string;
7163
8092
  /** Vendor version. */
7164
8093
  version?: string;
8094
+ static serialize(obj: any): ServerVendor.Transport;
8095
+ static deserialize(obj: any): ServerVendor;
8096
+ }
8097
+ namespace ServerVendor {
8098
+ interface Transport {
8099
+ name: string;
8100
+ variant?: string;
8101
+ version?: string;
8102
+ }
7165
8103
  }
7166
8104
  /** Schema for session authentication information. */
7167
- interface SessionAuthentication {
8105
+ class SessionAuthentication {
7168
8106
  /** authenticated. */
7169
8107
  authenticated?: string;
7170
8108
  /** authentication_db. */
7171
- authentication_db?: string;
8109
+ authenticationDb?: string;
7172
8110
  /** authentication_handlers. */
7173
- authentication_handlers: string[];
8111
+ authenticationHandlers: string[];
8112
+ static serialize(obj: any): SessionAuthentication.Transport;
8113
+ static deserialize(obj: any): SessionAuthentication;
8114
+ }
8115
+ namespace SessionAuthentication {
8116
+ interface Transport {
8117
+ authenticated?: string;
8118
+ authentication_db?: string;
8119
+ authentication_handlers: string[];
8120
+ }
7174
8121
  }
7175
8122
  /** Schema for information about a session. */
7176
- interface SessionInformation {
8123
+ class SessionInformation {
7177
8124
  /** ok. */
7178
8125
  ok: boolean;
7179
8126
  /** Schema for session authentication information. */
7180
8127
  info: SessionAuthentication;
7181
8128
  /** Schema for the user context of a session. */
7182
8129
  userCtx: UserContext;
8130
+ static serialize(obj: any): SessionInformation.Transport;
8131
+ static deserialize(obj: any): SessionInformation;
8132
+ }
8133
+ namespace SessionInformation {
8134
+ interface Transport {
8135
+ ok: boolean;
8136
+ info: SessionAuthentication.Transport;
8137
+ userCtx: UserContext.Transport;
8138
+ }
7183
8139
  }
7184
8140
  /** Schema for a shards object that maps the hash value range for each shard to the array of nodes that contain a copy of that shard. */
7185
- interface ShardsInformation {
8141
+ class ShardsInformation {
7186
8142
  /** Mapping of shard hash value range to a list of nodes. */
7187
8143
  shards: JsonObject;
8144
+ static serialize(obj: any): ShardsInformation.Transport;
8145
+ static deserialize(obj: any): ShardsInformation;
8146
+ }
8147
+ namespace ShardsInformation {
8148
+ interface Transport {
8149
+ shards: JsonObject;
8150
+ }
7188
8151
  }
7189
8152
  /** Schema for detailed information about throughput capacity with breakdown by specific throughput requests classes. */
7190
- interface ThroughputInformation {
8153
+ class ThroughputInformation {
7191
8154
  /** A number of blocks of throughput units. A block consists of 100 reads/sec, 50 writes/sec, and 5 global
7192
8155
  * queries/sec of provisioned throughput capacity.
7193
8156
  */
@@ -7198,13 +8161,25 @@ declare namespace CloudantV1 {
7198
8161
  read: number;
7199
8162
  /** Provisioned writes capacity in operations per second. */
7200
8163
  write: number;
8164
+ static serialize(obj: any): ThroughputInformation.Transport;
8165
+ static deserialize(obj: any): ThroughputInformation;
8166
+ }
8167
+ namespace ThroughputInformation {
8168
+ interface Transport {
8169
+ blocks: number;
8170
+ query: number;
8171
+ read: number;
8172
+ write: number;
8173
+ }
7201
8174
  }
7202
8175
  /** Schema for information about the up state of the server. */
7203
- interface UpInformation {
8176
+ class UpInformation {
7204
8177
  /** seeds. */
7205
8178
  seeds: JsonObject;
7206
8179
  /** status. */
7207
8180
  status: UpInformation.Constants.Status | string;
8181
+ static serialize(obj: any): UpInformation.Transport;
8182
+ static deserialize(obj: any): UpInformation;
7208
8183
  }
7209
8184
  namespace UpInformation {
7210
8185
  namespace Constants {
@@ -7215,9 +8190,13 @@ declare namespace CloudantV1 {
7215
8190
  OK = "ok"
7216
8191
  }
7217
8192
  }
8193
+ interface Transport {
8194
+ seeds: JsonObject;
8195
+ status: string;
8196
+ }
7218
8197
  }
7219
8198
  /** Schema for an ability to tell if view is up-to-date without querying it. */
7220
- interface UpdatesPending {
8199
+ class UpdatesPending {
7221
8200
  /** Sum of shard copies with the least amount of work to do. */
7222
8201
  minimum: number;
7223
8202
  /** Sum of unique shards. This value is zero when at least one copy of every shard range is up-to-date and the
@@ -7226,15 +8205,26 @@ declare namespace CloudantV1 {
7226
8205
  preferred: number;
7227
8206
  /** Sum of all shard copies. */
7228
8207
  total: number;
8208
+ static serialize(obj: any): UpdatesPending.Transport;
8209
+ static deserialize(obj: any): UpdatesPending;
8210
+ }
8211
+ namespace UpdatesPending {
8212
+ interface Transport {
8213
+ minimum: number;
8214
+ preferred: number;
8215
+ total: number;
8216
+ }
7229
8217
  }
7230
8218
  /** Schema for the user context of a session. */
7231
- interface UserContext {
8219
+ class UserContext {
7232
8220
  /** Database name in the context of the provided operation. */
7233
8221
  db?: string;
7234
8222
  /** User name. */
7235
- name: string;
8223
+ name: string | null;
7236
8224
  /** List of user roles. */
7237
8225
  roles: UserContext.Constants.Roles[] | string[];
8226
+ static serialize(obj: any): UserContext.Transport;
8227
+ static deserialize(obj: any): UserContext;
7238
8228
  }
7239
8229
  namespace UserContext {
7240
8230
  namespace Constants {
@@ -7250,25 +8240,44 @@ declare namespace CloudantV1 {
7250
8240
  SECURITY = "_security"
7251
8241
  }
7252
8242
  }
8243
+ interface Transport {
8244
+ db?: string;
8245
+ name: string;
8246
+ roles: string[];
8247
+ }
7253
8248
  }
7254
8249
  /** Schema for a set of uuids generated by the server. */
7255
- interface UuidsResult {
8250
+ class UuidsResult {
7256
8251
  /** uuids. */
7257
8252
  uuids: string[];
8253
+ static serialize(obj: any): UuidsResult.Transport;
8254
+ static deserialize(obj: any): UuidsResult;
8255
+ }
8256
+ namespace UuidsResult {
8257
+ interface Transport {
8258
+ uuids: string[];
8259
+ }
7258
8260
  }
7259
8261
  /** Schema for the results of a queries view operation. */
7260
- interface ViewQueriesResult {
8262
+ class ViewQueriesResult {
7261
8263
  /** An array of result objects - one for each query. Each result object contains the same fields as the response
7262
8264
  * to a regular view request.
7263
8265
  */
7264
8266
  results: ViewResult[];
8267
+ static serialize(obj: any): ViewQueriesResult.Transport;
8268
+ static deserialize(obj: any): ViewQueriesResult;
8269
+ }
8270
+ namespace ViewQueriesResult {
8271
+ interface Transport {
8272
+ results: ViewResult[];
8273
+ }
7265
8274
  }
7266
8275
  /** Schema for a query view operation. */
7267
- interface ViewQuery {
8276
+ class ViewQuery {
7268
8277
  /** Parameter to specify whether to include the encoding information in attachment stubs if the particular
7269
8278
  * attachment is compressed.
7270
8279
  */
7271
- att_encoding_info?: boolean;
8280
+ attEncodingInfo?: boolean;
7272
8281
  /** Parameter to specify whether to include attachments bodies in a response. */
7273
8282
  attachments?: boolean;
7274
8283
  /** Parameter to specify whether to include a list of conflicted revisions in each returned document. Active
@@ -7278,9 +8287,9 @@ declare namespace CloudantV1 {
7278
8287
  /** Parameter to specify whether to return the documents in descending by key order. */
7279
8288
  descending?: boolean;
7280
8289
  /** Parameter to specify whether to include the full content of the documents in the response. */
7281
- include_docs?: boolean;
8290
+ includeDocs?: boolean;
7282
8291
  /** Parameter to specify whether the specified end key should be included in the result. */
7283
- inclusive_end?: boolean;
8292
+ inclusiveEnd?: boolean;
7284
8293
  /** Parameter to specify the number of returned documents to limit the result to. */
7285
8294
  limit?: number;
7286
8295
  /** Parameter to specify the number of records before starting to return the results. */
@@ -7288,11 +8297,11 @@ declare namespace CloudantV1 {
7288
8297
  /** Parameter to specify whether to include in the response an update_seq value indicating the sequence id of
7289
8298
  * the database the view reflects.
7290
8299
  */
7291
- update_seq?: boolean;
8300
+ updateSeq?: boolean;
7292
8301
  /** Schema for any JSON type. */
7293
- end_key?: any;
8302
+ endKey?: any | null;
7294
8303
  /** Schema for a document ID. */
7295
- end_key_doc_id?: string;
8304
+ endKeyDocId?: string;
7296
8305
  /** Parameter to specify whether to group reduced results by key. Valid only if a reduce function defined in the
7297
8306
  * view. If the view emits key in JSON array format, then it is possible to reduce groups further based on the
7298
8307
  * number of array elements with the `group_level` parameter.
@@ -7302,9 +8311,9 @@ declare namespace CloudantV1 {
7302
8311
  * Implies group is `true`. Group level groups the reduced results by the specified number of array elements. If
7303
8312
  * unset, results are grouped by the entire array key, returning a reduced value for each complete key.
7304
8313
  */
7305
- group_level?: number;
8314
+ groupLevel?: number;
7306
8315
  /** Schema for any JSON type. */
7307
- key?: any;
8316
+ key?: any | null;
7308
8317
  /** Parameter to specify returning only documents that match any of the specified keys. A JSON array of keys
7309
8318
  * that match the key type emitted by the view function.
7310
8319
  */
@@ -7322,9 +8331,9 @@ declare namespace CloudantV1 {
7322
8331
  */
7323
8332
  stable?: boolean;
7324
8333
  /** Schema for any JSON type. */
7325
- start_key?: any;
8334
+ startKey?: any | null;
7326
8335
  /** Schema for a document ID. */
7327
- start_key_doc_id?: string;
8336
+ startKeyDocId?: string;
7328
8337
  /** Parameter to specify whether or not the view in question should be updated prior to responding to the user.
7329
8338
  *
7330
8339
  * * `true` - Return results after the view is updated.
@@ -7332,6 +8341,8 @@ declare namespace CloudantV1 {
7332
8341
  * * `lazy` - Return the view results without waiting for an update, but update them immediately after the request.
7333
8342
  */
7334
8343
  update?: ViewQuery.Constants.Update | string;
8344
+ static serialize(obj: any): ViewQuery.Transport;
8345
+ static deserialize(obj: any): ViewQuery;
7335
8346
  }
7336
8347
  namespace ViewQuery {
7337
8348
  namespace Constants {
@@ -7342,20 +8353,51 @@ declare namespace CloudantV1 {
7342
8353
  LAZY = "lazy"
7343
8354
  }
7344
8355
  }
8356
+ interface Transport {
8357
+ att_encoding_info?: boolean;
8358
+ attachments?: boolean;
8359
+ conflicts?: boolean;
8360
+ descending?: boolean;
8361
+ include_docs?: boolean;
8362
+ inclusive_end?: boolean;
8363
+ limit?: number;
8364
+ skip?: number;
8365
+ update_seq?: boolean;
8366
+ end_key?: any;
8367
+ end_key_doc_id?: string;
8368
+ group?: boolean;
8369
+ group_level?: number;
8370
+ key?: any;
8371
+ keys?: any[];
8372
+ reduce?: boolean;
8373
+ stable?: boolean;
8374
+ start_key?: any;
8375
+ start_key_doc_id?: string;
8376
+ update?: string;
8377
+ }
7345
8378
  }
7346
8379
  /** Schema for the result of a query view operation. */
7347
- interface ViewResult {
8380
+ class ViewResult {
7348
8381
  /** Number of total rows. */
7349
- total_rows?: number;
8382
+ totalRows?: number | null;
7350
8383
  /** Current update sequence for the database. */
7351
- update_seq?: string;
8384
+ updateSeq?: string;
7352
8385
  /** rows. */
7353
8386
  rows: ViewResultRow[];
8387
+ static serialize(obj: any): ViewResult.Transport;
8388
+ static deserialize(obj: any): ViewResult;
8389
+ }
8390
+ namespace ViewResult {
8391
+ interface Transport {
8392
+ total_rows?: number;
8393
+ update_seq?: string;
8394
+ rows: ViewResultRow[];
8395
+ }
7354
8396
  }
7355
8397
  /** Schema for a row of a view result. */
7356
- interface ViewResultRow {
8398
+ class ViewResultRow {
7357
8399
  /** The cause of the error (if available). */
7358
- caused_by?: string;
8400
+ causedBy?: string;
7359
8401
  /** The name of the error. */
7360
8402
  error?: string;
7361
8403
  /** The reason the error occurred (if available). */
@@ -7365,9 +8407,22 @@ declare namespace CloudantV1 {
7365
8407
  /** Schema for a document ID. */
7366
8408
  id?: string;
7367
8409
  /** Schema for any JSON type. */
7368
- key: any;
8410
+ key: any | null;
7369
8411
  /** Schema for any JSON type. */
7370
- value: any;
8412
+ value: any | null;
8413
+ static serialize(obj: any): ViewResultRow.Transport;
8414
+ static deserialize(obj: any): ViewResultRow;
8415
+ }
8416
+ namespace ViewResultRow {
8417
+ interface Transport {
8418
+ caused_by?: string;
8419
+ error?: string;
8420
+ reason?: string;
8421
+ doc?: Document.Transport;
8422
+ id?: string;
8423
+ key: any;
8424
+ value: any;
8425
+ }
7371
8426
  }
7372
8427
  }
7373
8428
  export = CloudantV1;