apollo-ai-api-client
Advanced tools
Comparing version 0.1.10 to 0.1.11
@@ -36,2 +36,4 @@ export interface IAutoAbstractResponse { | ||
apolloApiEndpoint: string; | ||
clusteringEndpoint: string; | ||
autoAbstractEndpoint: string; | ||
constructor(apiKey: string); | ||
@@ -38,0 +40,0 @@ autoabstract(headline: string, text: string, maxCharacters?: number, keywords?: string[], maxSentences?: number): Promise<IAutoAbstractResponse>; |
@@ -22,2 +22,4 @@ "use strict"; | ||
this.apolloApiEndpoint = 'https://api.apollo.ai/'; | ||
this.clusteringEndpoint = 'clustering'; | ||
this.autoAbstractEndpoint = 'autoabstract'; | ||
} | ||
@@ -40,3 +42,3 @@ autoabstract(headline, text, maxCharacters = 400, keywords, maxSentences = null) { | ||
} | ||
const response = yield node_fetch_1.default(this.apolloApiEndpoint + 'autoabstract', { | ||
const response = yield node_fetch_1.default(this.apolloApiEndpoint + this.autoAbstractEndpoint, { | ||
method: 'POST', | ||
@@ -58,3 +60,3 @@ headers: { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const url = new URL.URL(this.apolloApiEndpoint + 'clustering'); | ||
const url = new URL.URL(this.apolloApiEndpoint + this.clusteringEndpoint); | ||
url.searchParams.append('threshold', threshold.toString()); | ||
@@ -61,0 +63,0 @@ url.searchParams.append('language', language); |
{ | ||
"name": "apollo-ai-api-client", | ||
"version": "0.1.10", | ||
"version": "0.1.11", | ||
"description": "Client for the apollo.ai auto abstract api.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
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
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
9633
124