Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fintecture-client

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fintecture-client - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

dist/fintecture-client.d.ts

10

dist/fintecture-client.js

@@ -78,6 +78,6 @@ "use strict";

};
FintectureClient.prototype.getProviders = function (providerId) {
FintectureClient.prototype.getProviders = function (options) {
return __awaiter(this, void 0, void 0, function () {
return __generator(this, function (_a) {
return [2 /*return*/, this.resources.providers(providerId)];
return [2 /*return*/, this.resources.providers(options)];
});

@@ -93,6 +93,6 @@ });

};
FintectureClient.prototype.getTestAccounts = function (testAccountId) {
FintectureClient.prototype.getTestAccounts = function (options) {
return __awaiter(this, void 0, void 0, function () {
return __generator(this, function (_a) {
return [2 /*return*/, this.resources.testAccounts(testAccountId)];
return [2 /*return*/, this.resources.testAccounts(options)];
});

@@ -173,3 +173,3 @@ });

}
if (config.env && ['sandbox', 'production'].includes(this.config.env)) {
if (config.env && ['sandbox', 'production'].includes(config.env)) {
throw Error('environment is badly configured.');

@@ -176,0 +176,0 @@ }

@@ -89,3 +89,2 @@ "use strict";

connectUrlMin = _a.sent();
console.log("==>> connectUrlMin", connectUrlMin);
expect(connectUrlMin).toContain(mockConnectUrl);

@@ -95,3 +94,2 @@ return [4 /*yield*/, client.getPisConnectUrl(tokens.access_token, connectConfigFull)];

connectUrlFull = _a.sent();
console.log("==>> connectUrlFull", connectUrlFull);
expect(connectUrlFull).toContain(mockConnectUrl);

@@ -98,0 +96,0 @@ expect(connectUrlFull.length).toBeGreaterThan(connectUrlMin.length);

@@ -64,8 +64,15 @@ "use strict";

});
it('#providers(providerId)', function (done) {
it('#providers(options) PIS', function (done) {
return __awaiter(this, void 0, void 0, function () {
var body;
var options, body;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, client.getProviders('agfbfr')];
case 0:
options = {
'filter[pis]': 'sepa',
'filter[country]': 'FR',
'filter[psu_type]': 'retail',
'sort[full_name]': 'asc'
};
return [4 /*yield*/, client.getProviders(options)];
case 1:

@@ -80,2 +87,24 @@ body = _a.sent();

});
it('#providers(options) AIS', function (done) {
return __awaiter(this, void 0, void 0, function () {
var options, body;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
options = {
'filter[ais]': 'accounts',
'filter[country]': 'FR',
'filter[psu_type]': 'retail',
'sort[full_name]': 'asc'
};
return [4 /*yield*/, client.getProviders(options)];
case 1:
body = _a.sent();
expect(typeof body).toEqual('object');
done();
return [2 /*return*/];
}
});
});
});
it('#testAccounts()', function (done) {

@@ -96,8 +125,12 @@ return __awaiter(this, void 0, void 0, function () {

});
it('#testAccounts(testAccountId)', function (done) {
it('#testAccounts(options)', function (done) {
return __awaiter(this, void 0, void 0, function () {
var body;
var options, body;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, client.getTestAccounts('1')];
case 0:
options = {
'sort[provider]': 'asc'
};
return [4 /*yield*/, client.getTestAccounts(options)];
case 1:

@@ -104,0 +137,0 @@ body = _a.sent();

@@ -55,3 +55,3 @@ "use strict";

}
Resources.prototype.providers = function (providerId) {
Resources.prototype.providers = function (options) {
return __awaiter(this, void 0, void 0, function () {

@@ -63,3 +63,3 @@ var response;

this.axiosInstance.defaults.headers['app_id'] = this.appId;
return [4 /*yield*/, this.axiosInstance.get(ResourcesURLBuilder_1.ResourcesURLBuilder.getProviderURL(providerId))];
return [4 /*yield*/, this.axiosInstance.get(ResourcesURLBuilder_1.ResourcesURLBuilder.getProviderURL(options))];
case 1:

@@ -72,3 +72,3 @@ response = _a.sent();

};
Resources.prototype.testAccounts = function (testAccountId) {
Resources.prototype.testAccounts = function (options) {
return __awaiter(this, void 0, void 0, function () {

@@ -82,3 +82,3 @@ var response;

this.axiosInstance.defaults.headers['app_id'] = this.appId;
return [4 /*yield*/, this.axiosInstance.get(ResourcesURLBuilder_1.ResourcesURLBuilder.getTestAccountsURL(testAccountId))];
return [4 /*yield*/, this.axiosInstance.get(ResourcesURLBuilder_1.ResourcesURLBuilder.getTestAccountsURL(options))];
case 1:

@@ -85,0 +85,0 @@ response = _a.sent();

"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
var Endpoints_1 = require("./Endpoints");
var BaseUrls_1 = require("./BaseUrls");
var qs_1 = __importDefault(require("qs"));
var ResourcesURLBuilder = /** @class */ (function () {
function ResourcesURLBuilder() {
}
ResourcesURLBuilder.getProviderURL = function (providerID) {
if (providerID) {
return "" + BaseUrls_1.BaseUrls.FINTECTUREAPIURL_SBX + Endpoints_1.Endpoints.PROVIDERSURL + "/" + providerID;
ResourcesURLBuilder.getProviderURL = function (options) {
if (options && typeof options == 'object') {
return "" + BaseUrls_1.BaseUrls.FINTECTUREAPIURL_SBX + Endpoints_1.Endpoints.PROVIDERSURL + (options ? '?' + qs_1.default.stringify(options) : '');
}

@@ -16,5 +20,5 @@ else {

};
ResourcesURLBuilder.getTestAccountsURL = function (testAccountId) {
if (testAccountId) {
return "" + BaseUrls_1.BaseUrls.FINTECTUREAPIURL_SBX + Endpoints_1.Endpoints.TESTACCOUNTSURL + "/" + testAccountId;
ResourcesURLBuilder.getTestAccountsURL = function (options) {
if (options && typeof options == 'object') {
return "" + BaseUrls_1.BaseUrls.FINTECTUREAPIURL_SBX + Endpoints_1.Endpoints.TESTACCOUNTSURL + (options ? '?' + qs_1.default.stringify(options) : '');
}

@@ -21,0 +25,0 @@ else {

{
"name": "fintecture-client",
"version": "1.0.3",
"version": "1.0.4",
"description": "Fintecture Open Banking API Gateway enabling secure bank connections and payments",

@@ -12,5 +12,2 @@ "main": "dist/fintecture-client.js",

},
"files": [
"dist/**/*"
],
"author": "Fintecture.com",

@@ -38,3 +35,4 @@ "license": "MIT",

"typescript": "^3.7.2"
}
},
"files": ["dist/**/*"]
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc