Socket
Socket
Sign inDemoInstall

@sap-ux/btp-utils

Package Overview
Dependencies
22
Maintainers
3
Versions
26
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.14.3 to 0.14.4

9

dist/app-studio.d.ts

@@ -0,1 +1,2 @@

import type { Logger } from '@sap-ux/logger';
import type { Destination } from './destination';

@@ -42,2 +43,10 @@ /**

export declare function listDestinations(): Promise<Destinations>;
/**
* Exposes port in SAP Business Application Studio.
*
* @param port Port that needs to be exposed
* @param logger Logger
* @returns url on which the port is exposed
*/
export declare function exposePort(port: number, logger?: Logger): Promise<string>;
//# sourceMappingURL=app-studio.d.ts.map

22

dist/app-studio.js

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

Object.defineProperty(exports, "__esModule", { value: true });
exports.listDestinations = exports.getDestinationUrlForAppStudio = exports.getCredentialsForDestinationService = exports.getAppStudioProxyURL = exports.isAppStudio = exports.BAS_DEST_INSTANCE_CRED_HEADER = void 0;
exports.exposePort = exports.listDestinations = exports.getDestinationUrlForAppStudio = exports.getCredentialsForDestinationService = exports.getAppStudioProxyURL = exports.isAppStudio = exports.BAS_DEST_INSTANCE_CRED_HEADER = void 0;
const axios_1 = __importDefault(require("axios"));

@@ -102,2 +102,22 @@ const cf_tools_1 = require("@sap/cf-tools");

exports.listDestinations = listDestinations;
/**
* Exposes port in SAP Business Application Studio.
*
* @param port Port that needs to be exposed
* @param logger Logger
* @returns url on which the port is exposed
*/
function exposePort(port, logger) {
return __awaiter(this, void 0, void 0, function* () {
try {
const response = yield axios_1.default.get(`http://localhost:3001/AppStudio/api/getHostByPort?port=${port}`);
return `${response.data.result}`;
}
catch (error) {
logger === null || logger === void 0 ? void 0 : logger.error(`Port ${port} was not exposed!`);
return '';
}
});
}
exports.exposePort = exposePort;
//# sourceMappingURL=app-studio.js.map

5

package.json
{
"name": "@sap-ux/btp-utils",
"version": "0.14.3",
"version": "0.14.4",
"description": "Library to simplify working with SAP BTP specific features especially in SAP Business Application",

@@ -21,3 +21,4 @@ "repository": {

"devDependencies": {
"nock": "13.4.0"
"nock": "13.4.0",
"@sap-ux/logger": "0.5.1"
},

@@ -24,0 +25,0 @@ "files": [

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc