@adastradev/serverless-discovery-sdk
Advanced tools
Comparing version 0.0.7 to 0.1.0-beta1
@@ -5,3 +5,3 @@ export declare class DiscoverySdk { | ||
constructor(serviceEndpointUri: string, region?: string, defaultStageName?: string); | ||
lookupService(ServiceName: string, StageName?: string): Promise<any>; | ||
lookupService(serviceName: string, stageName?: string, version?: string, externalID?: string): Promise<any>; | ||
} |
@@ -47,4 +47,6 @@ "use strict"; | ||
} | ||
DiscoverySdk.prototype.lookupService = function (ServiceName, StageName) { | ||
if (StageName === void 0) { StageName = this.defaultStageName; } | ||
DiscoverySdk.prototype.lookupService = function (serviceName, stageName, version, externalID) { | ||
if (stageName === void 0) { stageName = this.defaultStageName; } | ||
if (version === void 0) { version = ''; } | ||
if (externalID === void 0) { externalID = ''; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
@@ -54,3 +56,3 @@ var result, matches; | ||
switch (_a.label) { | ||
case 0: return [4 /*yield*/, this.api.lookupService(ServiceName, StageName)]; | ||
case 0: return [4 /*yield*/, this.api.lookupService(serviceName, stageName, version, externalID)]; | ||
case 1: | ||
@@ -57,0 +59,0 @@ result = _a.sent(); |
@@ -8,5 +8,5 @@ import { ServiceApiModel } from './ServiceApiModel'; | ||
getService(id: string): any; | ||
lookupService(ServiceName: string, StageName?: string): any; | ||
lookupService(serviceName: string, stageName?: string, version?: string, externalID?: string): any; | ||
createService(service: ServiceApiModel): any; | ||
deleteService(id: string): any; | ||
} |
@@ -49,8 +49,10 @@ "use strict"; | ||
}; | ||
DiscoveryServiceApi.prototype.lookupService = function (ServiceName, StageName) { | ||
if (StageName === void 0) { StageName = ''; } | ||
DiscoveryServiceApi.prototype.lookupService = function (serviceName, stageName, version, externalID) { | ||
if (stageName === void 0) { stageName = ''; } | ||
if (version === void 0) { version = ''; } | ||
if (externalID === void 0) { externalID = ''; } | ||
var params = {}; | ||
var pathTemplate = '/catalog/service'; | ||
var method = 'GET'; | ||
var additionalParams = { queryParams: { ServiceName: ServiceName, StageName: StageName } }; | ||
var additionalParams = { queryParams: { 'ServiceName': serviceName, 'StageName': stageName, 'Version': version, 'ExternalID': externalID } }; | ||
var body = {}; | ||
@@ -57,0 +59,0 @@ return this.apigClient.invokeApi(params, pathTemplate, method, additionalParams, body); |
{ | ||
"name": "@adastradev/serverless-discovery-sdk", | ||
"version": "0.0.7", | ||
"version": "0.1.0-beta1", | ||
"description": "Serverless Service Discovery API", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
# serverless-discovery-sdk-js | ||
[![npm](https://img.shields.io/npm/v/%40adastradev%2Fserverless-discovery-sdk.svg)](https://www.npmjs.com/package/@adastradev/serverless-discovery-sdk) | ||
[![license](https://img.shields.io/npm/l/%40adastradev%2Fserverless-discovery-sdk.svg)](https://www.npmjs.com/package/@adastradev/serverless-discovery-sdk) | ||
*The last serverless micro-service you'll ever wonder how to find* | ||
@@ -4,0 +5,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15470
262
30
1