@nuclia/core
Advanced tools
Comparing version 1.9.1 to 1.10.0
@@ -0,1 +1,23 @@ | ||
# 1.10.0 (2024-01-08) | ||
### Breaking changes | ||
- Account slug is replaced by account id in several methods’ signature, and zone is required (except when using local NucliaDB instance): | ||
- getKnowledgeBox | ||
- createKnowledgeBox | ||
- getNUAClients | ||
- getNUAClient | ||
- createNUAClient | ||
- renewNUAClient | ||
- deleteNUAClient | ||
### Improvements | ||
- Add `v3starter`, `v3fly`, `v3growth` and `v3enterprise` to `AccountTypes` | ||
- Support `/rephrase` endpoint in KnowledgeBox | ||
- Add `generateRandomQuestionAboutResource` method | ||
- Add `index_size` in `Counters` model | ||
- Don't crash on `getToken` when local storage is disabled on the browser | ||
# 1.9.1 (2023-12-18) | ||
@@ -2,0 +24,0 @@ |
@@ -11,3 +11,2 @@ import { Observable } from 'rxjs'; | ||
private nuclia; | ||
private useRegionalSystem; | ||
constructor(nuclia: INuclia); | ||
@@ -38,5 +37,5 @@ /** Returns a list of all the accounts which are accessible for the current authenticated user. */ | ||
*/ | ||
modifyAccount(account: string, data: Partial<Account>): Observable<void>; | ||
modifyAccount(accountSlug: string, data: Partial<Account>): Observable<void>; | ||
/** Deletes an account. */ | ||
deleteAccount(account: string): Observable<void>; | ||
deleteAccount(accountSlug: string): Observable<void>; | ||
/** | ||
@@ -55,3 +54,3 @@ * Returns account status. | ||
*/ | ||
getAccountStatus(account: string): Observable<AccountStatus>; | ||
getAccountStatus(accountSlug: string): Observable<AccountStatus>; | ||
/** | ||
@@ -74,14 +73,23 @@ * Returns user information. | ||
getStandaloneKbs(): Observable<IStandaloneKb[]>; | ||
/** Returns a list of all the Knowledge Boxes for the given account slug. */ | ||
getKnowledgeBoxes(accountSlug: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns a list of all the Knowledge Boxes for the given account. Account slug and id can be provided in the Nuclia options or as parameters. | ||
*/ | ||
getKnowledgeBoxes(): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(accountSlug: string, accountId: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns the list of Knowledge Boxes for the given account id and zone. | ||
* @param accountId | ||
* @param zone | ||
*/ | ||
getKnowledgeBoxesForZone(accountId: string, zone: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns the Knowledge Box with the given slug, or the one defined in the Nuclia options | ||
* if no slug is provided. | ||
* Returns the Knowledge Box corresponding to the account id, Knowledge Box id and zone provided as parameters or the ones defined in the Nuclia options | ||
* if no parameters are provided. | ||
* Zone is mandatory except if the Knowledge Box is from a local NucliaDB instance. | ||
*/ | ||
getKnowledgeBox(): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(account: string, knowledgeBox: string): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(accountId: string, knowledgeBoxId: string, zone?: string): Observable<WritableKnowledgeBox>; | ||
/** | ||
* Creates a new Knowledge Box. | ||
* | ||
* Zone parameter is mandatory except if the Knowledge Box is from a local NucliaDB instance. | ||
* Example: | ||
@@ -93,3 +101,3 @@ ```ts | ||
}; | ||
nuclia.db.createKnowledgeBox('my-account', knowledgeBox).subscribe((knowledgeBox) => { | ||
nuclia.db.createKnowledgeBox('my-account-id', 'europe-1', knowledgeBox).subscribe((knowledgeBox) => { | ||
console.log('knowledge box', knowledgeBox); | ||
@@ -99,4 +107,4 @@ }); | ||
*/ | ||
createKnowledgeBox(account: string, knowledgeBox: KnowledgeBoxCreation): Observable<WritableKnowledgeBox>; | ||
getStats(account: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
createKnowledgeBox(accountId: string, knowledgeBox: KnowledgeBoxCreation, zone?: string): Observable<WritableKnowledgeBox>; | ||
getStats(accountSlug: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
/** | ||
@@ -131,4 +139,4 @@ * Uploads and pushes a file to Nuclia Understanding API. | ||
getNUAActivity(accountId: string, client_id: string, zoneSlug: string, pageIndex?: number): Observable<EventList>; | ||
getNUAClients(account: string): Observable<NUAClient[]>; | ||
getNUAClient(account: string, client_id: string): Observable<NUAClient>; | ||
getNUAClients(accountId: string): Observable<NUAClient[]>; | ||
getNUAClient(accountId: string, client_id: string, zone: string): Observable<NUAClient>; | ||
hasNUAClient(): boolean; | ||
@@ -139,4 +147,9 @@ getNUAKey(): string; | ||
}; | ||
/** Creates a NUA client and a NUA token. */ | ||
createNUAClient(account: string, data: NUAClientPayload): Observable<{ | ||
/** | ||
* Creates a NUA client and a NUA token. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
* @param accountId Account identifier | ||
* @param data NUA client data | ||
*/ | ||
createNUAClient(accountId: string, data: NUAClientPayload): Observable<{ | ||
client_id: string; | ||
@@ -149,4 +162,7 @@ token: string; | ||
}>; | ||
/** Renews a NUA token. */ | ||
renewNUAClient(account: string, client_id: string): Observable<{ | ||
/** | ||
* Renews a NUA token. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
*/ | ||
renewNUAClient(accountId: string, client_id: string): Observable<{ | ||
client_id: string; | ||
@@ -159,4 +175,7 @@ token: string; | ||
}>; | ||
/** Deletes a NUA client. */ | ||
deleteNUAClient(account: string, client_id: string): Observable<void>; | ||
/** | ||
* Deletes a NUA client. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
*/ | ||
deleteNUAClient(accountId: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string, zone: string): Observable<void>; | ||
@@ -163,0 +182,0 @@ getLearningConfigurations(): Observable<LearningConfigurations>; |
@@ -1,2 +0,2 @@ | ||
export type AccountTypes = 'stash-basic' | 'stash-team' | 'stash-trial' | 'stash-startup' | 'stash-starter' | 'stash-growth' | 'stash-enterprise' | 'stash-developer' | 'stash-business'; | ||
export type AccountTypes = 'stash-trial' | 'v3starter' | 'v3fly' | 'v3growth' | 'v3enterprise' | 'stash-basic' | 'stash-team' | 'stash-startup' | 'stash-starter' | 'stash-growth' | 'stash-enterprise' | 'stash-developer' | 'stash-business'; | ||
export declare const NUA_KEY = "NUCLIA_NUA_KEY"; | ||
@@ -3,0 +3,0 @@ export interface Account { |
@@ -24,3 +24,2 @@ import { Observable } from 'rxjs'; | ||
private tempToken?; | ||
protected useRegionalSystem: boolean; | ||
/** | ||
@@ -178,2 +177,32 @@ * The Knowledge Box path on the regional API. | ||
}>; | ||
/** | ||
* Performs a question rephrasing operation. | ||
* It returns a rephrased question that can be used as input for the `generate()` method. | ||
* Example: | ||
```ts | ||
nuclia.knowledgeBox | ||
.rephrase('Eric lives Toronto') | ||
.subscribe((rephrased) => { | ||
console.log('rephrased', rephrased); // Where does Eric live? | ||
}); | ||
``` | ||
*/ | ||
rephrase(question: string): Observable<string>; | ||
/** | ||
* Generates a random question about the given resource. | ||
* It picks an entities relation from the extracted metadata and generates a question about it. | ||
* It returns an empty string if no question can be generated. | ||
* Example: | ||
```ts | ||
nuclia.knowledgeBox | ||
.getResource('09a94719a6444c5a9689394f6ed9baf6', [ResourceProperties.EXTRACTED], [ExtractedDataTypes.METADATA]) | ||
.pipe( | ||
switchMap((resource) => knowledgeBox.generateRandomQuestionAboutResource(resource)), | ||
) | ||
.subscribe((question) => { | ||
console.log('question', question); | ||
}); | ||
``` | ||
*/ | ||
generateRandomQuestionAboutResource(resource: Resource): Observable<string>; | ||
catalog(query: string, options?: SearchOptions): Observable<Search.Results | IErrorResponse>; | ||
@@ -189,2 +218,3 @@ /** Suggests paragraphs based on the given query. */ | ||
* Returns an ephemeral token. | ||
* Requires account id and zone to be set in the Nuclia options (except when working with a local NucliaDB instance). | ||
* | ||
@@ -191,0 +221,0 @@ * This is useful when displaying a clickable link to a file in a private Knowledge Box |
@@ -79,2 +79,4 @@ import type { Observable } from 'rxjs'; | ||
}>; | ||
rephrase(question: string): Observable<string>; | ||
generateRandomQuestionAboutResource(resource: Resource): Observable<string>; | ||
catalog(query: string, options?: SearchOptions): Observable<Search.Results | IErrorResponse>; | ||
@@ -137,3 +139,2 @@ suggest(query: string): Observable<Search.Suggestions | IErrorResponse>; | ||
description?: string; | ||
zone?: string; | ||
learning_configuration?: { | ||
@@ -191,3 +192,2 @@ [configId: string]: any; | ||
navigateToFile?: boolean; | ||
targetNewTab?: boolean; | ||
navigateToLink?: boolean; | ||
@@ -216,2 +216,3 @@ notPublic?: boolean; | ||
sentences: number; | ||
index_size: number; | ||
} | ||
@@ -218,0 +219,0 @@ export interface ResourceList { |
@@ -75,5 +75,5 @@ import type { Observable } from 'rxjs'; | ||
createAccount(account: AccountCreation): Observable<Account>; | ||
getAccountStatus(account: string): Observable<AccountStatus>; | ||
modifyAccount(account: string, data: Partial<Account>): Observable<void>; | ||
deleteAccount(account: string): Observable<void>; | ||
getAccountStatus(accountSlug: string): Observable<AccountStatus>; | ||
modifyAccount(accountSlug: string, data: Partial<Account>): Observable<void>; | ||
deleteAccount(accountSlug: string): Observable<void>; | ||
getWelcome(): Observable<Welcome>; | ||
@@ -83,8 +83,9 @@ getAccount(): Observable<Account>; | ||
getStandaloneKbs(): Observable<IStandaloneKb[]>; | ||
getKnowledgeBoxes(accountSlug: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(accountSlug: string, accountId: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxesForZone(accountId: string, zone: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBox(): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(account: string, knowledgeBox: string): Observable<WritableKnowledgeBox>; | ||
createKnowledgeBox(account: string, knowledgeBox: KnowledgeBoxCreation): Observable<WritableKnowledgeBox>; | ||
getStats(account: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
getKnowledgeBox(accountId: string, knowledgeBoxId: string, zone?: string): Observable<WritableKnowledgeBox>; | ||
createKnowledgeBox(accountId: string, knowledgeBox: KnowledgeBoxCreation, zone?: string): Observable<WritableKnowledgeBox>; | ||
getStats(accountSlug: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
upload(file: File): Observable<ProcessingPushResponse>; | ||
@@ -94,5 +95,5 @@ getProcessingStatus(accountId?: string): Observable<ProcessingStatusResponse>; | ||
pull(): Observable<ProcessingPullResponse>; | ||
getNUAClients(account: string): Observable<NUAClient[]>; | ||
getNUAClient(account: string, client_id: string): Observable<NUAClient>; | ||
createNUAClient(account: string, data: NUAClientPayload): Observable<{ | ||
getNUAClients(accountId: string): Observable<NUAClient[]>; | ||
getNUAClient(accountId: string, client_id: string, zone: string): Observable<NUAClient>; | ||
createNUAClient(accountId: string, data: NUAClientPayload): Observable<{ | ||
client_id: string; | ||
@@ -105,3 +106,3 @@ token: string; | ||
}>; | ||
renewNUAClient(account: string, client_id: string): Observable<{ | ||
renewNUAClient(accountId: string, client_id: string): Observable<{ | ||
client_id: string; | ||
@@ -114,3 +115,3 @@ token: string; | ||
}>; | ||
deleteNUAClient(account: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string, zone: string): Observable<void>; | ||
@@ -117,0 +118,0 @@ hasNUAClient(): boolean; |
@@ -60,3 +60,3 @@ import { Observable } from 'rxjs'; | ||
getObjectURL(path: string): Observable<string>; | ||
getStream(path: string, body: any): Observable<{ | ||
getStream(path: string, body: unknown): Observable<{ | ||
data: Uint8Array; | ||
@@ -63,0 +63,0 @@ incomplete: boolean; |
{ | ||
"name": "@nuclia/core", | ||
"version": "1.9.1", | ||
"version": "1.10.0", | ||
"description": "SDK allowing to integrate Nuclia services in your frontend application", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -11,3 +11,2 @@ import { Observable } from 'rxjs'; | ||
private nuclia; | ||
private useRegionalSystem; | ||
constructor(nuclia: INuclia); | ||
@@ -38,5 +37,5 @@ /** Returns a list of all the accounts which are accessible for the current authenticated user. */ | ||
*/ | ||
modifyAccount(account: string, data: Partial<Account>): Observable<void>; | ||
modifyAccount(accountSlug: string, data: Partial<Account>): Observable<void>; | ||
/** Deletes an account. */ | ||
deleteAccount(account: string): Observable<void>; | ||
deleteAccount(accountSlug: string): Observable<void>; | ||
/** | ||
@@ -55,3 +54,3 @@ * Returns account status. | ||
*/ | ||
getAccountStatus(account: string): Observable<AccountStatus>; | ||
getAccountStatus(accountSlug: string): Observable<AccountStatus>; | ||
/** | ||
@@ -74,14 +73,23 @@ * Returns user information. | ||
getStandaloneKbs(): Observable<IStandaloneKb[]>; | ||
/** Returns a list of all the Knowledge Boxes for the given account slug. */ | ||
getKnowledgeBoxes(accountSlug: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns a list of all the Knowledge Boxes for the given account. Account slug and id can be provided in the Nuclia options or as parameters. | ||
*/ | ||
getKnowledgeBoxes(): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(accountSlug: string, accountId: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns the list of Knowledge Boxes for the given account id and zone. | ||
* @param accountId | ||
* @param zone | ||
*/ | ||
getKnowledgeBoxesForZone(accountId: string, zone: string): Observable<IKnowledgeBoxItem[]>; | ||
/** | ||
* Returns the Knowledge Box with the given slug, or the one defined in the Nuclia options | ||
* if no slug is provided. | ||
* Returns the Knowledge Box corresponding to the account id, Knowledge Box id and zone provided as parameters or the ones defined in the Nuclia options | ||
* if no parameters are provided. | ||
* Zone is mandatory except if the Knowledge Box is from a local NucliaDB instance. | ||
*/ | ||
getKnowledgeBox(): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(account: string, knowledgeBox: string): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(accountId: string, knowledgeBoxId: string, zone?: string): Observable<WritableKnowledgeBox>; | ||
/** | ||
* Creates a new Knowledge Box. | ||
* | ||
* Zone parameter is mandatory except if the Knowledge Box is from a local NucliaDB instance. | ||
* Example: | ||
@@ -93,3 +101,3 @@ ```ts | ||
}; | ||
nuclia.db.createKnowledgeBox('my-account', knowledgeBox).subscribe((knowledgeBox) => { | ||
nuclia.db.createKnowledgeBox('my-account-id', 'europe-1', knowledgeBox).subscribe((knowledgeBox) => { | ||
console.log('knowledge box', knowledgeBox); | ||
@@ -99,4 +107,4 @@ }); | ||
*/ | ||
createKnowledgeBox(account: string, knowledgeBox: KnowledgeBoxCreation): Observable<WritableKnowledgeBox>; | ||
getStats(account: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
createKnowledgeBox(accountId: string, knowledgeBox: KnowledgeBoxCreation, zone?: string): Observable<WritableKnowledgeBox>; | ||
getStats(accountSlug: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
/** | ||
@@ -131,4 +139,4 @@ * Uploads and pushes a file to Nuclia Understanding API. | ||
getNUAActivity(accountId: string, client_id: string, zoneSlug: string, pageIndex?: number): Observable<EventList>; | ||
getNUAClients(account: string): Observable<NUAClient[]>; | ||
getNUAClient(account: string, client_id: string): Observable<NUAClient>; | ||
getNUAClients(accountId: string): Observable<NUAClient[]>; | ||
getNUAClient(accountId: string, client_id: string, zone: string): Observable<NUAClient>; | ||
hasNUAClient(): boolean; | ||
@@ -139,4 +147,9 @@ getNUAKey(): string; | ||
}; | ||
/** Creates a NUA client and a NUA token. */ | ||
createNUAClient(account: string, data: NUAClientPayload): Observable<{ | ||
/** | ||
* Creates a NUA client and a NUA token. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
* @param accountId Account identifier | ||
* @param data NUA client data | ||
*/ | ||
createNUAClient(accountId: string, data: NUAClientPayload): Observable<{ | ||
client_id: string; | ||
@@ -149,4 +162,7 @@ token: string; | ||
}>; | ||
/** Renews a NUA token. */ | ||
renewNUAClient(account: string, client_id: string): Observable<{ | ||
/** | ||
* Renews a NUA token. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
*/ | ||
renewNUAClient(accountId: string, client_id: string): Observable<{ | ||
client_id: string; | ||
@@ -159,4 +175,7 @@ token: string; | ||
}>; | ||
/** Deletes a NUA client. */ | ||
deleteNUAClient(account: string, client_id: string): Observable<void>; | ||
/** | ||
* Deletes a NUA client. | ||
* Zone parameter must be provided except when working with a local NucliaDB instance. | ||
*/ | ||
deleteNUAClient(accountId: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string, zone: string): Observable<void>; | ||
@@ -163,0 +182,0 @@ getLearningConfigurations(): Observable<LearningConfigurations>; |
@@ -1,2 +0,2 @@ | ||
export type AccountTypes = 'stash-basic' | 'stash-team' | 'stash-trial' | 'stash-startup' | 'stash-starter' | 'stash-growth' | 'stash-enterprise' | 'stash-developer' | 'stash-business'; | ||
export type AccountTypes = 'stash-trial' | 'v3starter' | 'v3fly' | 'v3growth' | 'v3enterprise' | 'stash-basic' | 'stash-team' | 'stash-startup' | 'stash-starter' | 'stash-growth' | 'stash-enterprise' | 'stash-developer' | 'stash-business'; | ||
export declare const NUA_KEY = "NUCLIA_NUA_KEY"; | ||
@@ -3,0 +3,0 @@ export interface Account { |
@@ -24,3 +24,2 @@ import { Observable } from 'rxjs'; | ||
private tempToken?; | ||
protected useRegionalSystem: boolean; | ||
/** | ||
@@ -178,2 +177,32 @@ * The Knowledge Box path on the regional API. | ||
}>; | ||
/** | ||
* Performs a question rephrasing operation. | ||
* It returns a rephrased question that can be used as input for the `generate()` method. | ||
* Example: | ||
```ts | ||
nuclia.knowledgeBox | ||
.rephrase('Eric lives Toronto') | ||
.subscribe((rephrased) => { | ||
console.log('rephrased', rephrased); // Where does Eric live? | ||
}); | ||
``` | ||
*/ | ||
rephrase(question: string): Observable<string>; | ||
/** | ||
* Generates a random question about the given resource. | ||
* It picks an entities relation from the extracted metadata and generates a question about it. | ||
* It returns an empty string if no question can be generated. | ||
* Example: | ||
```ts | ||
nuclia.knowledgeBox | ||
.getResource('09a94719a6444c5a9689394f6ed9baf6', [ResourceProperties.EXTRACTED], [ExtractedDataTypes.METADATA]) | ||
.pipe( | ||
switchMap((resource) => knowledgeBox.generateRandomQuestionAboutResource(resource)), | ||
) | ||
.subscribe((question) => { | ||
console.log('question', question); | ||
}); | ||
``` | ||
*/ | ||
generateRandomQuestionAboutResource(resource: Resource): Observable<string>; | ||
catalog(query: string, options?: SearchOptions): Observable<Search.Results | IErrorResponse>; | ||
@@ -189,2 +218,3 @@ /** Suggests paragraphs based on the given query. */ | ||
* Returns an ephemeral token. | ||
* Requires account id and zone to be set in the Nuclia options (except when working with a local NucliaDB instance). | ||
* | ||
@@ -191,0 +221,0 @@ * This is useful when displaying a clickable link to a file in a private Knowledge Box |
@@ -79,2 +79,4 @@ import type { Observable } from 'rxjs'; | ||
}>; | ||
rephrase(question: string): Observable<string>; | ||
generateRandomQuestionAboutResource(resource: Resource): Observable<string>; | ||
catalog(query: string, options?: SearchOptions): Observable<Search.Results | IErrorResponse>; | ||
@@ -137,3 +139,2 @@ suggest(query: string): Observable<Search.Suggestions | IErrorResponse>; | ||
description?: string; | ||
zone?: string; | ||
learning_configuration?: { | ||
@@ -191,3 +192,2 @@ [configId: string]: any; | ||
navigateToFile?: boolean; | ||
targetNewTab?: boolean; | ||
navigateToLink?: boolean; | ||
@@ -216,2 +216,3 @@ notPublic?: boolean; | ||
sentences: number; | ||
index_size: number; | ||
} | ||
@@ -218,0 +219,0 @@ export interface ResourceList { |
@@ -75,5 +75,5 @@ import type { Observable } from 'rxjs'; | ||
createAccount(account: AccountCreation): Observable<Account>; | ||
getAccountStatus(account: string): Observable<AccountStatus>; | ||
modifyAccount(account: string, data: Partial<Account>): Observable<void>; | ||
deleteAccount(account: string): Observable<void>; | ||
getAccountStatus(accountSlug: string): Observable<AccountStatus>; | ||
modifyAccount(accountSlug: string, data: Partial<Account>): Observable<void>; | ||
deleteAccount(accountSlug: string): Observable<void>; | ||
getWelcome(): Observable<Welcome>; | ||
@@ -83,8 +83,9 @@ getAccount(): Observable<Account>; | ||
getStandaloneKbs(): Observable<IStandaloneKb[]>; | ||
getKnowledgeBoxes(accountSlug: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxes(accountSlug: string, accountId: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBoxesForZone(accountId: string, zone: string): Observable<IKnowledgeBoxItem[]>; | ||
getKnowledgeBox(): Observable<WritableKnowledgeBox>; | ||
getKnowledgeBox(account: string, knowledgeBox: string): Observable<WritableKnowledgeBox>; | ||
createKnowledgeBox(account: string, knowledgeBox: KnowledgeBoxCreation): Observable<WritableKnowledgeBox>; | ||
getStats(account: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
getKnowledgeBox(accountId: string, knowledgeBoxId: string, zone?: string): Observable<WritableKnowledgeBox>; | ||
createKnowledgeBox(accountId: string, knowledgeBox: KnowledgeBoxCreation, zone?: string): Observable<WritableKnowledgeBox>; | ||
getStats(accountSlug: string, type: StatsType, knowledgeBox?: string, period?: StatsPeriod, utctime?: string): Observable<ProcessingStat[]>; | ||
upload(file: File): Observable<ProcessingPushResponse>; | ||
@@ -94,5 +95,5 @@ getProcessingStatus(accountId?: string): Observable<ProcessingStatusResponse>; | ||
pull(): Observable<ProcessingPullResponse>; | ||
getNUAClients(account: string): Observable<NUAClient[]>; | ||
getNUAClient(account: string, client_id: string): Observable<NUAClient>; | ||
createNUAClient(account: string, data: NUAClientPayload): Observable<{ | ||
getNUAClients(accountId: string): Observable<NUAClient[]>; | ||
getNUAClient(accountId: string, client_id: string, zone: string): Observable<NUAClient>; | ||
createNUAClient(accountId: string, data: NUAClientPayload): Observable<{ | ||
client_id: string; | ||
@@ -105,3 +106,3 @@ token: string; | ||
}>; | ||
renewNUAClient(account: string, client_id: string): Observable<{ | ||
renewNUAClient(accountId: string, client_id: string): Observable<{ | ||
client_id: string; | ||
@@ -114,3 +115,3 @@ token: string; | ||
}>; | ||
deleteNUAClient(account: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string): Observable<void>; | ||
deleteNUAClient(accountId: string, client_id: string, zone: string): Observable<void>; | ||
@@ -117,0 +118,0 @@ hasNUAClient(): boolean; |
@@ -60,3 +60,3 @@ import { Observable } from 'rxjs'; | ||
getObjectURL(path: string): Observable<string>; | ||
getStream(path: string, body: any): Observable<{ | ||
getStream(path: string, body: unknown): Observable<{ | ||
data: Uint8Array; | ||
@@ -63,0 +63,0 @@ incomplete: boolean; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
409780
8146