regenerated open api services

This commit is contained in:
2026-05-29 05:06:04 +02:00
parent 916ec5fa61
commit 708dd13ca0
3 changed files with 214 additions and 2 deletions
+180
View File
@@ -102,6 +102,66 @@ export class PersonsOpenApiService extends BaseService implements PersonsOpenApi
);
}
/**
* Searches for person by ID.
* @endpoint get /persons/id
* @param authorId OpenAlex author ID (e.g., A5093075883)
* @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.
*/
public getPersonByID(authorId: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<PersonSearchResult>;
public getPersonByID(authorId: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpResponse<PersonSearchResult>>;
public getPersonByID(authorId: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpEvent<PersonSearchResult>>;
public getPersonByID(authorId: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<any> {
if (authorId === null || authorId === undefined) {
throw new Error('Required parameter authorId was null or undefined when calling getPersonByID.');
}
let localVarQueryParameters = new HttpParams({encoder: this.encoder});
localVarQueryParameters = this.addToHttpParams(localVarQueryParameters,
<any>authorId, 'author_id');
let localVarHeaders = this.defaultHeaders;
const localVarHttpHeaderAcceptSelected: string | undefined = options?.httpHeaderAccept ?? this.configuration.selectHeaderAccept([
'application/json'
]);
if (localVarHttpHeaderAcceptSelected !== undefined) {
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
}
const localVarHttpContext: HttpContext = options?.context ?? new HttpContext();
const localVarTransferCache: boolean = options?.transferCache ?? true;
let responseType_: 'text' | 'json' | 'blob' = 'json';
if (localVarHttpHeaderAcceptSelected) {
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
responseType_ = 'text';
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
responseType_ = 'json';
} else {
responseType_ = 'blob';
}
}
let localVarPath = `/persons/id`;
const { basePath, withCredentials } = this.configuration;
return this.httpClient.request<PersonSearchResult>('get', `${basePath}${localVarPath}`,
{
context: localVarHttpContext,
params: localVarQueryParameters,
responseType: <any>responseType_,
...(withCredentials ? { withCredentials } : {}),
headers: localVarHeaders,
observe: observe,
...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}),
reportProgress: reportProgress
}
);
}
/**
* Searches for persons by ID or name.
* @endpoint get /persons/search
@@ -165,4 +225,124 @@ export class PersonsOpenApiService extends BaseService implements PersonsOpenApi
);
}
/**
* Searches for persons by institution name.
* @endpoint get /persons/searchByInstitution
* @param institutionName Institution name (e.g., MIT, Oxford University)
* @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.
*/
public searchPersonsByInstitution(institutionName: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<PersonSearchResult>;
public searchPersonsByInstitution(institutionName: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpResponse<PersonSearchResult>>;
public searchPersonsByInstitution(institutionName: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpEvent<PersonSearchResult>>;
public searchPersonsByInstitution(institutionName: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<any> {
if (institutionName === null || institutionName === undefined) {
throw new Error('Required parameter institutionName was null or undefined when calling searchPersonsByInstitution.');
}
let localVarQueryParameters = new HttpParams({encoder: this.encoder});
localVarQueryParameters = this.addToHttpParams(localVarQueryParameters,
<any>institutionName, 'institution_name');
let localVarHeaders = this.defaultHeaders;
const localVarHttpHeaderAcceptSelected: string | undefined = options?.httpHeaderAccept ?? this.configuration.selectHeaderAccept([
'application/json'
]);
if (localVarHttpHeaderAcceptSelected !== undefined) {
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
}
const localVarHttpContext: HttpContext = options?.context ?? new HttpContext();
const localVarTransferCache: boolean = options?.transferCache ?? true;
let responseType_: 'text' | 'json' | 'blob' = 'json';
if (localVarHttpHeaderAcceptSelected) {
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
responseType_ = 'text';
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
responseType_ = 'json';
} else {
responseType_ = 'blob';
}
}
let localVarPath = `/persons/searchByInstitution`;
const { basePath, withCredentials } = this.configuration;
return this.httpClient.request<PersonSearchResult>('get', `${basePath}${localVarPath}`,
{
context: localVarHttpContext,
params: localVarQueryParameters,
responseType: <any>responseType_,
...(withCredentials ? { withCredentials } : {}),
headers: localVarHeaders,
observe: observe,
...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}),
reportProgress: reportProgress
}
);
}
/**
* Searches for person by name.
* @endpoint get /persons/searchByName
* @param authorName Authors name (e.g., Arman Arzani)
* @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.
*/
public searchPersonsByName(authorName: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<PersonSearchResult>;
public searchPersonsByName(authorName: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpResponse<PersonSearchResult>>;
public searchPersonsByName(authorName: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<HttpEvent<PersonSearchResult>>;
public searchPersonsByName(authorName: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable<any> {
if (authorName === null || authorName === undefined) {
throw new Error('Required parameter authorName was null or undefined when calling searchPersonsByName.');
}
let localVarQueryParameters = new HttpParams({encoder: this.encoder});
localVarQueryParameters = this.addToHttpParams(localVarQueryParameters,
<any>authorName, 'author_name');
let localVarHeaders = this.defaultHeaders;
const localVarHttpHeaderAcceptSelected: string | undefined = options?.httpHeaderAccept ?? this.configuration.selectHeaderAccept([
'application/json'
]);
if (localVarHttpHeaderAcceptSelected !== undefined) {
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
}
const localVarHttpContext: HttpContext = options?.context ?? new HttpContext();
const localVarTransferCache: boolean = options?.transferCache ?? true;
let responseType_: 'text' | 'json' | 'blob' = 'json';
if (localVarHttpHeaderAcceptSelected) {
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
responseType_ = 'text';
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
responseType_ = 'json';
} else {
responseType_ = 'blob';
}
}
let localVarPath = `/persons/searchByName`;
const { basePath, withCredentials } = this.configuration;
return this.httpClient.request<PersonSearchResult>('get', `${basePath}${localVarPath}`,
{
context: localVarHttpContext,
params: localVarQueryParameters,
responseType: <any>responseType_,
...(withCredentials ? { withCredentials } : {}),
headers: localVarHeaders,
observe: observe,
...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}),
reportProgress: reportProgress
}
);
}
}
@@ -32,6 +32,14 @@ export interface PersonsOpenApiServiceInterface {
*/
generatePersonBio(authorId: string, extraHttpRequestParams?: any): Observable<PersonBio>;
/**
* Searches for person by ID.
*
* @endpoint get /persons/id
* @param authorId OpenAlex author ID (e.g., A5093075883)
*/
getPersonByID(authorId: string, extraHttpRequestParams?: any): Observable<PersonSearchResult>;
/**
* Searches for persons by ID or name.
*
@@ -42,4 +50,20 @@ export interface PersonsOpenApiServiceInterface {
*/
searchPersons(authorId?: string, query?: string, include?: string, extraHttpRequestParams?: any): Observable<PersonSearchResult>;
/**
* Searches for persons by institution name.
*
* @endpoint get /persons/searchByInstitution
* @param institutionName Institution name (e.g., MIT, Oxford University)
*/
searchPersonsByInstitution(institutionName: string, extraHttpRequestParams?: any): Observable<PersonSearchResult>;
/**
* Searches for person by name.
*
* @endpoint get /persons/searchByName
* @param authorName Authors name (e.g., Arman Arzani)
*/
searchPersonsByName(authorName: string, extraHttpRequestParams?: any): Observable<PersonSearchResult>;
}
+10 -2
View File
@@ -18,7 +18,15 @@ export const routes: Routes = [
),
},
{
path: 'person/:id',
path: 'persons',
canActivate: [userGuard],
loadComponent: () =>
import('./modules/person-list/person-list.component').then(
(mod) => mod.PersonListComponent,
),
},
{
path: 'persons/:id',
canActivate: [userGuard],
loadComponent: () =>
import('./modules/person/person.component').then(
@@ -51,7 +59,7 @@ export const routes: Routes = [
(mod) => mod.PersonPublicationsComponent,
),
},
],
]
},
{
path: '**',