@verdocs/js-sdk 1.1.5 → 1.1.6

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.
@@ -102,7 +102,9 @@ export var getDocument = function (documentId) { return __awaiter(void 0, void 0
102
102
  export var getDocumentFile = function (documentId, envelopeDocumentId) { return __awaiter(void 0, void 0, void 0, function () {
103
103
  return __generator(this, function (_a) {
104
104
  return [2 /*return*/, getEndpoint()
105
- .api.get("/documents/".concat(documentId, "/envelope_documents/").concat(envelopeDocumentId, "?file=true"))
106
- .then(function (r) { return r.data; })];
105
+ .api.get("/documents/".concat(documentId, "/envelope_documents/").concat(envelopeDocumentId, "?file=true"), {
106
+ responseType: 'arraybuffer',
107
+ })
108
+ .then(function (r) { return Buffer.from(r.data, 'binary').toString('base64'); })];
107
109
  });
108
110
  }); };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@verdocs/js-sdk",
3
- "version": "1.1.5",
3
+ "version": "1.1.6",
4
4
  "private": false,
5
5
  "homepage": "https://github.com/Verdocs/js-sdk",
6
6
  "description": "Verdocs JS SDK",