@ibm-cloud/cloudant 0.0.19 → 0.0.23

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/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
  [![Release](https://img.shields.io/github/v/release/IBM/cloudant-node-sdk?include_prereleases&sort=semver)](https://github.com/IBM/cloudant-node-sdk/releases/latest)
3
3
  [![Docs](https://img.shields.io/static/v1?label=TypeDoc&message=latest&color=blue)](https://ibm.github.io/cloudant-node-sdk/)
4
4
 
5
- # IBM Cloudant Node.js SDK Version 0.0.19
5
+ # IBM Cloudant Node.js SDK Version 0.0.23
6
6
 
7
7
  IBM Cloudant Node.js SDK is a client library that interacts with the
8
8
  [IBM Cloudant APIs](https://cloud.ibm.com/apidocs/cloudant?code=node).
@@ -106,12 +106,12 @@ npm install @ibm-cloud/cloudant
106
106
 
107
107
  ## Authentication
108
108
 
109
- [service-credentials]: https://cloud.ibm.com/docs/Cloudant?topic=cloudant-creating-an-ibm-cloudant-instance-on-ibm-cloud#locating-your-service-credentials
110
- [cloud-IAM-mgmt]: https://cloud.ibm.com/docs/Cloudant?topic=cloudant-ibm-cloud-identity-and-access-management-iam-
109
+ [service-credentials]: https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-locating-your-service-credentials
110
+ [cloud-IAM-mgmt]: https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-managing-access-for-cloudant#introduction-iam-ai
111
111
  [couch-cookie-auth]: https://docs.couchdb.org/en/stable/api/server/authn.html#cookie-authentication
112
- [cloudant-cookie-auth]: https://cloud.ibm.com/docs/Cloudant?topic=cloudant-authentication#cookie-authentication
112
+ [cloudant-cookie-auth]: https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-work-with-your-account#cookie-authentication
113
113
  [couch-basic-auth]: https://docs.couchdb.org/en/stable/api/server/authn.html#basic-authentication
114
- [cloudant-basic-auth]: https://cloud.ibm.com/docs/services/Cloudant/api?topic=cloudant-authentication#basic-authentication
114
+ [cloudant-basic-auth]: https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-work-with-your-account#basic-authentication
115
115
 
116
116
  This library requires some of your
117
117
  [Cloudant service credentials][service-credentials] to authenticate with your
@@ -208,9 +208,11 @@ For fundamental SDK usage information and config options, please see the common
208
208
 
209
209
  ### Request timeout configuration
210
210
 
211
- No request, read or connect timeouts are set by default. Be sure to set a request timeout appropriate to your application usage and environment.
211
+ No request timeout is defined, but a 2.5m connect and 2.5m read timeout is set by default. Be sure to set a request timeout appropriate to your application usage and environment.
212
212
  The [request timeout](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md) section contains details on how to change the value.
213
213
 
214
+ **Note:** System settings may take precedence over configured timeout values.
215
+
214
216
  ### Code examples
215
217
 
216
218
  The following code examples
@@ -256,7 +258,7 @@ const client = CloudantV1.newInstance({ serviceName: 'EXAMPLES' });
256
258
  // 2. Get server information ==================================================
257
259
  // call service without parameters:
258
260
  client.getServerInformation().then((serverInformation) => {
259
- const version = serverInformation.result.version;
261
+ const { version } = serverInformation.result;
260
262
  console.log(`Server version ${version}`);
261
263
  });
262
264
 
@@ -270,7 +272,7 @@ client.getDatabaseInformation({ db: dbName }).then((dbInfo) => {
270
272
 
271
273
  // 4. Show document count in database =================================
272
274
  console.log(
273
- `Document count in "${dbNameResult}" database is ` + documentCount + '.'
275
+ `Document count in "${dbNameResult}" database is ${documentCount}.`
274
276
  );
275
277
  });
276
278
 
@@ -283,9 +285,9 @@ const getDocParams: CloudantV1.GetDocumentParams = {
283
285
  // call service with predefined parameters:
284
286
  client.getDocument(getDocParams).then((documentAboutZebra) => {
285
287
  // result object is defined as a Document here:
286
- const result: CloudantV1.Document = documentAboutZebra.result;
288
+ const { result } = documentAboutZebra;
287
289
  console.log(
288
- 'Document retrieved from database:\n' + JSON.stringify(result, null, 2)
290
+ `Document retrieved from database:\n${JSON.stringify(result, null, 2)}`
289
291
  );
290
292
  });
291
293
  ```
@@ -305,7 +307,7 @@ const getInfoFromExistingDatabase = async () => {
305
307
 
306
308
  // 2. Get server information ==================================================
307
309
  // call service without parameters:
308
- const version = (await client.getServerInformation()).result.version;
310
+ const { version } = (await client.getServerInformation()).result;
309
311
  console.log(`Server version ${version}`);
310
312
 
311
313
  // 3. Get database information for "animaldb" =================================
@@ -318,7 +320,7 @@ const getInfoFromExistingDatabase = async () => {
318
320
 
319
321
  // 4. Show document count in database =================================
320
322
  console.log(
321
- `Document count in "${dbNameResult}" database is ` + documentCount + '.'
323
+ `Document count in "${dbNameResult}" database is ${documentCount}.`
322
324
  );
323
325
 
324
326
  // 5. Get zebra document out of the database by document id ===================
@@ -328,10 +330,10 @@ const getInfoFromExistingDatabase = async () => {
328
330
  const documentAboutZebra = await client.getDocument(getDocParams);
329
331
 
330
332
  // result object is defined as a Document here:
331
- const result = documentAboutZebra.result;
333
+ const { result } = documentAboutZebra;
332
334
 
333
335
  console.log(
334
- 'Document retrieved from database:\n' + JSON.stringify(result, null, 2)
336
+ `Document retrieved from database:\n${JSON.stringify(result, null, 2)}`
335
337
  );
336
338
  };
337
339
 
@@ -404,7 +406,7 @@ const createDb = client
404
406
  .catch((err) => {
405
407
  if (err.code === 412) {
406
408
  console.log(
407
- 'Cannot create "' + exampleDbName + '" database, it already exists.'
409
+ `Cannot create "${exampleDbName}" database, it already exists.`
408
410
  );
409
411
  }
410
412
  });
@@ -467,7 +469,7 @@ const createDbAndDoc = async () => {
467
469
  } catch (err) {
468
470
  if (err.code === 412) {
469
471
  console.log(
470
- 'Cannot create "' + exampleDbName + '" database, it already exists.'
472
+ `Cannot create "${exampleDbName}" database, it already exists.`
471
473
  );
472
474
  }
473
475
  }
@@ -579,7 +581,7 @@ client
579
581
 
580
582
  // Update the document in the database
581
583
  client
582
- .postDocument({ db: exampleDbName, document: document })
584
+ .postDocument({ db: exampleDbName, document })
583
585
  // Note: for request byte stream use:
584
586
  // .postDocument(
585
587
  // {db: exampleDbName, document: documentAsByteStream}
@@ -588,17 +590,15 @@ client
588
590
  // Keeping track with the revision number of the document object:
589
591
  document._rev = res.result.rev;
590
592
  console.log(
591
- 'You have updated the document:\n' + JSON.stringify(document, null, 2)
593
+ `You have updated the document:\n${JSON.stringify(document, null, 2)}`
592
594
  );
593
595
  });
594
596
  })
595
597
  .catch((err) => {
596
598
  if (err.code === 404) {
597
599
  console.log(
598
- 'Cannot update document because either "' +
599
- exampleDbName +
600
- '" database or the "example" ' +
601
- 'document was not found.'
600
+ `Cannot update document because either "${exampleDbName}" database or the "example" ` +
601
+ `document was not found.`
602
602
  );
603
603
  }
604
604
  });
@@ -647,7 +647,7 @@ const updateDoc = async () => {
647
647
  document._rev = (
648
648
  await client.postDocument({
649
649
  db: exampleDbName,
650
- document: document,
650
+ document,
651
651
  })
652
652
  ).result.rev;
653
653
 
@@ -660,15 +660,13 @@ const updateDoc = async () => {
660
660
  // ).result.rev;
661
661
 
662
662
  console.log(
663
- 'You have updated the document:\n' + JSON.stringify(document, null, 2)
663
+ `You have updated the document:\n${JSON.stringify(document, null, 2)}`
664
664
  );
665
665
  } catch (err) {
666
666
  if (err.code === 404) {
667
667
  console.log(
668
- 'Cannot update document because either "' +
669
- exampleDbName +
670
- '" database or the "example" ' +
671
- 'document was not found.'
668
+ `Cannot update document because either "${exampleDbName}" database or the "example" ` +
669
+ `document was not found.`
672
670
  );
673
671
  }
674
672
  }
@@ -754,10 +752,8 @@ client
754
752
  .catch((err) => {
755
753
  if (err.code === 404) {
756
754
  console.log(
757
- 'Cannot delete document because either "' +
758
- exampleDbName +
759
- '" database or the "example" ' +
760
- 'document was not found.'
755
+ `Cannot delete document because either "${exampleDbName}" database or the "example" ` +
756
+ `document was not found.`
761
757
  );
762
758
  }
763
759
  });
@@ -799,10 +795,8 @@ const deleteDoc = async () => {
799
795
  } catch (err) {
800
796
  if (err.code === 404) {
801
797
  console.log(
802
- 'Cannot delete document because either "' +
803
- exampleDbName +
804
- '" database or the "example" ' +
805
- 'document was not found.'
798
+ `Cannot delete document because either "${exampleDbName}" database or the "example" ` +
799
+ `document was not found.`
806
800
  );
807
801
  }
808
802
  }
@@ -38,6 +38,7 @@ export declare class CouchdbSessionAuthenticator extends Authenticator {
38
38
  protected tokenManager: SessionTokenManager;
39
39
  protected requiredOptions: ['username', 'password'];
40
40
  private tokenOptions;
41
+ static readonly AUTHTYPE_COUCHDB_SESSION = "COUCHDB_SESSION";
41
42
  /**
42
43
  * Create a new CouchdbSessionAuthenticator instance.
43
44
  *
@@ -64,4 +65,10 @@ export declare class CouchdbSessionAuthenticator extends Authenticator {
64
65
  * @param {object} userOptions - Configuration values for a `request` service.
65
66
  */
66
67
  configure(userOptions: UserOptions): void;
68
+ /**
69
+ * Returns the authenticator's type ('COUCHDB_SESSION').
70
+ *
71
+ * @returns a string that indicates the authenticator's type
72
+ */
73
+ authenticationType(): string;
67
74
  }
@@ -29,6 +29,17 @@ var __extends = (this && this.__extends) || (function () {
29
29
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
30
30
  };
31
31
  })();
32
+ var __assign = (this && this.__assign) || function () {
33
+ __assign = Object.assign || function(t) {
34
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
35
+ s = arguments[i];
36
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
37
+ t[p] = s[p];
38
+ }
39
+ return t;
40
+ };
41
+ return __assign.apply(this, arguments);
42
+ };
32
43
  Object.defineProperty(exports, "__esModule", { value: true });
33
44
  exports.CouchdbSessionAuthenticator = void 0;
34
45
  var ibm_cloud_sdk_core_1 = require("ibm-cloud-sdk-core");
@@ -58,7 +69,7 @@ var CouchdbSessionAuthenticator = /** @class */ (function (_super) {
58
69
  function CouchdbSessionAuthenticator(options) {
59
70
  var _this = _super.call(this) || this;
60
71
  (0, ibm_cloud_sdk_core_1.validateInput)(options, _this.requiredOptions);
61
- _this.tokenOptions = Object.assign({}, options);
72
+ _this.tokenOptions = __assign({}, options);
62
73
  return _this;
63
74
  }
64
75
  /**
@@ -90,13 +101,13 @@ var CouchdbSessionAuthenticator = /** @class */ (function (_super) {
90
101
  cookieJar.cloudantPatch = true;
91
102
  // Replace the store's updateCookie function with one that applies a patch to newCookie
92
103
  var originalUpdateCookieFn_1 = cookieJar.store.updateCookie;
93
- cookieJar.store.updateCookie = function (oldCookie, newCookie, cb) {
104
+ cookieJar.store.updateCookie = function updateCookie(oldCookie, newCookie, cb) {
94
105
  // Add current time as an update timestamp to the newCookie
95
106
  newCookie.cloudantPatchUpdateTime = new Date();
96
107
  // Replace the cookie's expiryTime function with one that uses cloudantPatchUpdateTime
97
108
  // in place of creation time to check the expiry.
98
109
  var originalExpiryTimeFn = newCookie.expiryTime;
99
- newCookie.expiryTime = function (now) {
110
+ newCookie.expiryTime = function expiryTime(now) {
100
111
  // The original expiryTime check is relative to a time in this order:
101
112
  // 1. supplied now argument
102
113
  // 2. this.creation (original cookie creation time)
@@ -120,6 +131,16 @@ var CouchdbSessionAuthenticator = /** @class */ (function (_super) {
120
131
  // Set the token manager
121
132
  this.tokenManager = new sessionTokenManager_1.SessionTokenManager(this.tokenOptions);
122
133
  };
134
+ /**
135
+ * Returns the authenticator's type ('COUCHDB_SESSION').
136
+ *
137
+ * @returns a string that indicates the authenticator's type
138
+ */
139
+ // eslint-disable-next-line class-methods-use-this
140
+ CouchdbSessionAuthenticator.prototype.authenticationType = function () {
141
+ return CouchdbSessionAuthenticator.AUTHTYPE_COUCHDB_SESSION;
142
+ };
143
+ CouchdbSessionAuthenticator.AUTHTYPE_COUCHDB_SESSION = 'COUCHDB_SESSION';
123
144
  return CouchdbSessionAuthenticator;
124
145
  }(ibm_cloud_sdk_core_1.Authenticator));
125
146
  exports.CouchdbSessionAuthenticator = CouchdbSessionAuthenticator;
@@ -1 +1 @@
1
- {"version":3,"file":"couchdbSessionAuthenticator.js","sourceRoot":"","sources":["../../auth/couchdbSessionAuthenticator.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;;;;;;;;;AAEH,yDAA+E;AAC/E,6DAG+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,SAAS,EACT,SAAS,CAAC,uBAAuB,IAAI,GAAG,CACzC,CAAC;gBACJ,CAAC,CAAC;gBACF,oGAAoG;gBACpG,uGAAuG;gBACvG,+CAA+C;gBAC/C,IAAI,wBAAsB,EAAE;oBAC1B,wBAAsB,CAAC,IAAI,CACzB,SAAS,CAAC,KAAK,EACf,SAAS,EACT,SAAS,EACT,EAAE,CACH,CAAC;iBACH;qBAAM;oBACL,SAAS,CAAC,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,CAAC,CAAC;iBAChE;YACH,CAAC,CAAC;SACH;QACD,8BAA8B;QAE9B,wBAAwB;QACxB,IAAI,CAAC,YAAY,GAAG,IAAI,yCAAmB,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;IACjE,CAAC;IACH,kCAAC;AAAD,CAAC,AAxFD,CAAiD,kCAAa,GAwF7D;AAxFY,kEAA2B"}
1
+ {"version":3,"file":"couchdbSessionAuthenticator.js","sourceRoot":"","sources":["../../auth/couchdbSessionAuthenticator.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,yDAA+E;AAC/E,6DAG+B;AAU/B;;;;;;;;;;;GAWG;AACH;IAAiD,+CAAa;IAS5D;;;;;;;OAOG;IACH,qCAAY,OAA2C;QAAvD,YACE,iBAAO,SAGR;QAFC,IAAA,kCAAa,EAAC,OAAO,EAAE,KAAI,CAAC,eAAe,CAAC,CAAC;QAC7C,KAAI,CAAC,YAAY,gBAAQ,OAAO,CAAE,CAAC;;IACrC,CAAC;IAED;;;;;;;;OAQG;IACI,kDAAY,GAAnB,UAAoB,cAAsB;QACxC,OAAO,IAAI,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC;IACtC,CAAC;IAED;;;;;OAKG;IACI,+CAAS,GAAhB,UAAiB,WAAwB;QACvC,oBAAoB;QACpB,MAAM,CAAC,MAAM,CAAC,I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AAC,IAAI,CAAC,YAAY,CAAC,CAAC;IACjE,CAAC;IAED;;;;OAIG;IACH,kDAAkD;IAC3C,wDAAkB,GAAzB;QACE,OAAO,2BAA2B,CAAC,wBAAwB,CAAC;IAC9D,CAAC;IAlGe,oDAAwB,GAAG,iBAAiB,CAAC;IAmG/D,kCAAC;CAAA,AA1GD,CAAiD,kCAAa,GA0G7D;AA1GY,kEAA2B"}
@@ -75,6 +75,7 @@ var SessionTokenManager = /** @class */ (function (_super) {
75
75
  * @param {OutgoingHttpHeaders} headers - the new set of headers as an object
76
76
  * @returns {Error}
77
77
  */
78
+ // eslint-disable-next-line class-methods-use-this
78
79
  SessionTokenManager.prototype.setHeaders = function (headers) {
79
80
  var errMsg = 'During CouchDB Session Authentication only `request` service headers are in use';
80
81
  throw new Error(errMsg);
@@ -92,7 +93,7 @@ var SessionTokenManager = /** @class */ (function (_super) {
92
93
  var parameters = {
93
94
  options: {
94
95
  headers: this.options.headers,
95
- url: this.options.serviceUrl + '/_session',
96
+ url: "".concat(this.options.serviceUrl, "/_session"),
96
97
  method: 'POST',
97
98
  body: {
98
99
  username: this.options.username,
@@ -120,7 +121,7 @@ var SessionTokenManager = /** @class */ (function (_super) {
120
121
  var sessionToken = null;
121
122
  var expireTime = null;
122
123
  var refreshTime = null;
123
- for (var i = 0; i < sessionCookie.length && sessionToken == null; i++) {
124
+ for (var i = 0; i < sessionCookie.length && sessionToken == null; i += 1) {
124
125
  sessionToken = new RegExp('AuthSession=([^;]*);').exec(sessionCookie[i]);
125
126
  if (sessionToken != null) {
126
127
  expireTime = new RegExp('.*Expires=([^;]*);').exec(sessionCookie[i]);
@@ -1 +1 @@
1
- {"version":3,"file":"sessionTokenManager.js","sourceRoot":"","sources":["../../auth/sessionTokenManager.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;;;;;;;;;AAGH,yDAK4B;AAU5B;;;;;GAKG;AACH;IAAyC,uCAAY;IAUnD;;;;;;;;;;;;;;;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