UNPKG

@finbourne/lusid-sdk-angular16

Version:

An angular (16) SDK for secure access to the LUSID® by FINBOURNE web API

193 lines (192 loc) 15.2 kB
import { HttpClient, HttpHeaders, HttpResponse, HttpEvent, HttpParameterCodec, HttpContext } from '@angular/common/http'; import { Observable } from 'rxjs'; import { Dialect } from '../model/dialect'; import { PagedResourceListOfDialectId } from '../model/pagedResourceListOfDialectId'; import { PagedResourceListOfTranslationScriptId } from '../model/pagedResourceListOfTranslationScriptId'; import { TranslateEntitiesInlinedRequest } from '../model/translateEntitiesInlinedRequest'; import { TranslateEntitiesRequest } from '../model/translateEntitiesRequest'; import { TranslateEntitiesResponse } from '../model/translateEntitiesResponse'; import { TranslationScript } from '../model/translationScript'; import { UpsertDialectRequest } from '../model/upsertDialectRequest'; import { UpsertTranslationScriptRequest } from '../model/upsertTranslationScriptRequest'; import { Configuration } from '../configuration'; import * as i0 from "@angular/core"; export declare class ScriptedTranslationService { protected httpClient: HttpClient; protected basePath: string; defaultHeaders: HttpHeaders; configuration: Configuration; encoder: HttpParameterCodec; constructor(httpClient: HttpClient, basePath: string | string[], configuration: Configuration); private addToHttpParams; private addToHttpParamsRecursive; /** * [EARLY ACCESS] GetTranslationDialect: Get a dialect. * Get the dialect with the given identifier at the specific asAt time. * @param scope The scope of the dialect. * @param vendor The vendor of the dialect, the entity that created it. e.g. ISDA, FINBOURNE. * @param sourceSystem The source system of the dialect, the system that understands it. e.g. LUSID, QuantLib. * @param entityType The type of entity this dialect describes e.g. Instrument. * @param serialisationFormat The serialisation format of a document in this dialect. e.g. JSON, XML. * @param version The semantic version of the dialect: MAJOR.MINOR.PATCH. * @param asAt The asAt datetime at which to retrieve the dialect. Defaults to return the latest version of the dialect if not specified. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ getTranslationDialect(scope: string, vendor: string, sourceSystem: string, entityType: string, serialisationFormat: string, version: string, asAt?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<Dialect>; getTranslationDialect(scope: string, vendor: string, sourceSystem: string, entityType: string, serialisationFormat: string, version: string, asAt?: string, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<Dialect>>; getTranslationDialect(scope: string, vendor: string, sourceSystem: string, entityType: string, serialisationFormat: string, version: string, asAt?: string, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<Dialect>>; /** * [EARLY ACCESS] GetTranslationScript: Retrieve a translation script by its identifier. * Retrieves a translation script to be used for translating financial entities. * @param scope Scope of the translation script. * @param code Code of the translation script. * @param version Semantic version of the translation script. * @param asAt The asAt datetime at which to retrieve the translation script. Defaults to latest. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ getTranslationScript(scope: string, code: string, version: string, asAt?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<TranslationScript>; getTranslationScript(scope: string, code: string, version: string, asAt?: string, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<TranslationScript>>; getTranslationScript(scope: string, code: string, version: string, asAt?: string, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<TranslationScript>>; /** * [EARLY ACCESS] ListDialectIds: List dialect identifiers matching an optional filter. * List the stored dialects\&#39; identifiers with pagination and filtering at the specified asAt time. * @param asAt The asAt datetime at which to retrieve the dialects. Defaults to return the latest version of the dialect if not specified. * @param page The pagination token to use to continue listing dialect IDs from a previous call to list dialect IDs. This value is returned from the previous call. If a pagination token is provided the filter and asAt fields must not have changed since the original request. * @param limit When paginating, limit the number of returned results to this many. * @param filter Expression to filter the result set. Read more about filtering results from LUSID here: https://support.lusid.com/filtering-results-from-lusid. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ listDialectIds(asAt?: string, page?: string, limit?: number, filter?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<PagedResourceListOfDialectId>; listDialectIds(asAt?: string, page?: string, limit?: number, filter?: string, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<PagedResourceListOfDialectId>>; listDialectIds(asAt?: string, page?: string, limit?: number, filter?: string, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<PagedResourceListOfDialectId>>; /** * [EARLY ACCESS] ListTranslationScriptIds: List translation script identifiers. * List translation script ids. * @param asAt The asAt datetime at which to retrieve the script identifiers. Defaults to latest. * @param limit When paginating, limit the results to this number. Defaults to 100 if not specified. * @param filter Expression to filter the results. For example, Id.Version.Major eq 1 to list IDs with major version 1 or Id.Scope eq \&#39;my-scripts\&#39; to list result only for a particular scope. * @param page The pagination token to use to continue listing translation script IDs; this value is returned from the previous call. If a pagination token is provided, the filter field must not have changed since the original request. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ listTranslationScriptIds(asAt?: string, limit?: number, filter?: string, page?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<PagedResourceListOfTranslationScriptId>; listTranslationScriptIds(asAt?: string, limit?: number, filter?: string, page?: string, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<PagedResourceListOfTranslationScriptId>>; listTranslationScriptIds(asAt?: string, limit?: number, filter?: string, page?: string, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<PagedResourceListOfTranslationScriptId>>; /** * [EARLY ACCESS] TranslateEntities: Translate a collection of entities with a specified translation script. * Run the provided translation request. The entities to translate are specified in the request body as a dictionary with (ephemeral) unique correlation IDs. The script to use and optional dialect to validate results against are sourced from the database. * @param translateEntitiesRequest The entities to translate, along with identifiers for the script and (optional) dialect to use. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ translateEntities(translateEntitiesRequest: TranslateEntitiesRequest, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<TranslateEntitiesResponse>; translateEntities(translateEntitiesRequest: TranslateEntitiesRequest, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<TranslateEntitiesResponse>>; translateEntities(translateEntitiesRequest: TranslateEntitiesRequest, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<TranslateEntitiesResponse>>; /** * [EARLY ACCESS] TranslateEntitiesInlined: Translate a collection of entities, inlining the body of the translation script. * Run the provided translation request. The entities to translate, script to use and dialect to validate results against are all specified in the request body. The entities are given as a dictionary with (ephemeral) unique correlation IDs. * @param translateEntitiesInlinedRequest The entities to translate, along with the script to use and an optional schema for validation. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ translateEntitiesInlined(translateEntitiesInlinedRequest: TranslateEntitiesInlinedRequest, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<TranslateEntitiesResponse>; translateEntitiesInlined(translateEntitiesInlinedRequest: TranslateEntitiesInlinedRequest, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<TranslateEntitiesResponse>>; translateEntitiesInlined(translateEntitiesInlinedRequest: TranslateEntitiesInlinedRequest, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<TranslateEntitiesResponse>>; /** * [EARLY ACCESS] UpsertTranslationDialect: Upsert a Dialect. * Upsert the given dialect. * @param upsertDialectRequest The dialect to upsert. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ upsertTranslationDialect(upsertDialectRequest: UpsertDialectRequest, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<Dialect>; upsertTranslationDialect(upsertDialectRequest: UpsertDialectRequest, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<Dialect>>; upsertTranslationDialect(upsertDialectRequest: UpsertDialectRequest, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<Dialect>>; /** * [EARLY ACCESS] UpsertTranslationScript: Upsert a translation script. * Upserts a translation script to be used for translating financial entities. * @param upsertTranslationScriptRequest The translation script to be upserted. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ upsertTranslationScript(upsertTranslationScriptRequest: UpsertTranslationScriptRequest, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<TranslationScript>; upsertTranslationScript(upsertTranslationScriptRequest: UpsertTranslationScriptRequest, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpResponse<TranslationScript>>; upsertTranslationScript(upsertTranslationScriptRequest: UpsertTranslationScriptRequest, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'text/plain' | 'application/json' | 'text/json'; context?: HttpContext; }): Observable<HttpEvent<TranslationScript>>; static ɵfac: i0.ɵɵFactoryDeclaration<ScriptedTranslationService, [null, { optional: true; }, { optional: true; }]>; static ɵprov: i0.ɵɵInjectableDeclaration<ScriptedTranslationService>; }