Skip to content

Releases: montumodi/mongodb-atlas-api-client

Dropped support for Node >18. Also upgraded Urllib

09 Sep 19:45
Compare
Choose a tag to compare

Dropped support for nodejs version less than 18. Urllib has also been updated to latest version. Some more dev dependencies were updated as part of this release.

Dropped `node-fetch` and used `urllib`

20 May 15:08
Compare
Choose a tag to compare

This library uses digest authentication which was implemented using node-fetch and digest-fetch. These packages recently has introduced some vulnerabilities and it was not possible to move to higher version because of incompatibility between node-fetch and digest-fetch. To mitigate this issue, these have now been replaced with urllib.

Ideally there shouldn't be any breaking change in this but since underlying library has been changed so there could be some changes on how errors are retuened. Happy scenarios should work as it. If you face any issue while using version 3 of this library, feel free to raise an issue.

As part of improvement a new options called httpOptions has been introduced (via options) which can be used to send some specific http options supported by urllib library. For more information, see readme seciton.

For example to send a custom timeout following code can be used

const getClient = require("mongodb-atlas-api-client");
const {user, cluster} = getClient({
  "publicKey": "some public key",
  "privateKey": "some private key",
  "baseUrl": "https://cloud.mongodb.com/api/atlas/v1.0",
  "projectId": "some project/group id"
});

const options = {
  "envelope": true,
  "itemsPerPage": 10,
  "pretty": true,
  "httpOptions": { // This parameter will not be sent as querystring. This will be send to http request package `urllib`
    "timeout": 5000
  }
}

const response = await user.getAll(options); // get All users

Dropped support for Node Verison 8

16 May 17:46
Compare
Choose a tag to compare
  • Upgraded eslint to major version
  • Dropped support node 8