diff --git a/service/src/main/inse/model.py b/service/src/main/inse/model.py index 83c064c3..882338ad 100644 --- a/service/src/main/inse/model.py +++ b/service/src/main/inse/model.py @@ -52,6 +52,9 @@ class ESIndex(StrEnum): OPENALEX_CONTINENTS = "openalex-continents" OPENALEX_TOPICS = "openalex-topics" OPENALEX_TOPIC_VECTORS = "topicvectors" + OPENALEX_DOMAINS = "openalex-domains" + OPENALEX_FIELDS = "openalex-fields" + OPENALEX_SUBFIELDS = "openalex-subfields" EPO_INDEX = "epo_index_1.0" USPTO_INDEX = "uspto_patents_3.0" diff --git a/service/src/main/inse/topics/v2/router.py b/service/src/main/inse/topics/v2/router.py index f382d5a0..0a7fe43a 100644 --- a/service/src/main/inse/topics/v2/router.py +++ b/service/src/main/inse/topics/v2/router.py @@ -4,6 +4,9 @@ from typing import Annotated import inse.topics.v2.service as topics_service from fastapi import APIRouter, Path, Query from inse.model import SortDirection +from inse.models.openalex.domain import Domain +from inse.models.openalex.model_field import ModelField +from inse.models.openalex.subfield import Subfield from inse.models.openalex.topic import Topic from inse.router_prefixes import RouterPrefixes from inse.tags import Tags @@ -78,6 +81,48 @@ async def get_topic_by_id( ) +@router.get( + "/domains/single/{domain_id}", + operation_id="getDomainById", + summary="Returns a domain for a given domain ID.", +) +async def get_domain_by_id( + domain_id: Annotated[ + str, + Path(description="The ID of the domain to retrieve."), + ], +) -> Domain: + return await topics_service.get_domain_by_id_or_raise(domain_id=domain_id) + + +@router.get( + "/fields/single/{field_id}", + operation_id="getFieldById", + summary="Returns a field for a given field ID.", +) +async def get_field_by_id( + field_id: Annotated[ + str, + Path(description="The ID of the field to retrieve."), + ], +) -> ModelField: + return await topics_service.get_field_by_id_or_raise(field_id=field_id) + + +@router.get( + "/subfields/single/{subfield_id}", + operation_id="getSubfieldById", + summary="Returns a subfield for a given subfield ID.", +) +async def get_subfield_by_id( + subfield_id: Annotated[ + str, + Path(description="The ID of the subfield to retrieve."), + ], +) -> Subfield: + return await topics_service.get_subfield_by_id_or_raise(subfield_id=subfield_id) + + @router.get( "/topics/id", operation_id="getTopicsByIds", diff --git a/service/src/main/inse/topics/v2/service.py b/service/src/main/inse/topics/v2/service.py index b73379d8..b10c7d60 100644 --- a/service/src/main/inse/topics/v2/service.py +++ b/service/src/main/inse/topics/v2/service.py @@ -1,6 +1,9 @@ from inse.exceptions import NotFoundException from inse.integrations import elasticsearch from inse.model import ESIndex, SortDirection +from inse.models.openalex.domain import Domain +from inse.models.openalex.model_field import ModelField +from inse.models.openalex.subfield import Subfield from inse.models.openalex.topic import Topic from inse.topics.v2.model import TopicPageV2, TopicSortBy @@ -184,6 +187,117 @@ async def get_topic_by_id_or_raise(raw_oa_topic_id: str) -> Topic: return topic +async def get_domain_by_id(domain_id: str) -> Domain | None: + """Retrieves a domain based on its ID. + + Args: + domain_id (str): The numeric OpenAlex ID of the domain to retrieve (e.g. "4"). + + Returns: + Domain | None: The domain matching the provided ID, or None if not found. + """ + response = await elasticsearch.get( + index=ESIndex.OPENALEX_DOMAINS, + doc_id=domain_id, + source=["id", "display_name", "description"], + ) + if response.get("found"): + return Domain.from_dict(response.get("_source", {})) + return None + + +async def get_domain_by_id_or_raise(domain_id: str) -> Domain: + """Retrieves a domain based on its ID, raising an exception if not found. + + Args: + domain_id (str): The ID of the domain to retrieve. + + Raises: + NotFoundException: If the domain with the specified ID is not found. + + Returns: + Domain: The domain matching the provided ID. + """ + domain = await get_domain_by_id(domain_id) + if domain is None: + raise NotFoundException(f"Domain with ID {domain_id} not found.") + return domain + + +async def get_field_by_id(field_id: str) -> ModelField | None: + """Retrieves a field based on its ID. + + Args: + field_id (str): The numeric OpenAlex ID of the field to retrieve (e.g. "27"). + + Returns: + ModelField | None: The field matching the provided ID, or None if not found. + """ + response = await elasticsearch.get( + index=ESIndex.OPENALEX_FIELDS, + doc_id=field_id, + source=["id", "display_name", "description"], + ) + if response.get("found"): + return ModelField.from_dict(response.get("_source", {})) + return None + + +async def get_field_by_id_or_raise(field_id: str) -> ModelField: + """Retrieves a field based on its ID, raising an exception if not found. + + Args: + field_id (str): The ID of the field to retrieve. + + Raises: + NotFoundException: If the field with the specified ID is not found. + + Returns: + ModelField: The field matching the provided ID. + """ + field = await get_field_by_id(field_id) + if field is None: + raise NotFoundException(f"Field with ID {field_id} not found.") + return field + + +async def get_subfield_by_id(subfield_id: str) -> Subfield | None: + """Retrieves a subfield based on its ID. + + Args: + subfield_id (str): The numeric OpenAlex ID of the subfield to retrieve (e.g. "2743"). + + Returns: + Subfield | None: The subfield matching the provided ID, or None if not found. + """ + response = await elasticsearch.get( + index=ESIndex.OPENALEX_SUBFIELDS, + doc_id=subfield_id, + source=["id", "display_name", "description"], + ) + if response.get("found"): + return Subfield.from_dict(response.get("_source", {})) + return None + + +async def get_subfield_by_id_or_raise(subfield_id: str) -> Subfield: + """Retrieves a subfield based on its ID, raising an exception if not found. + + Args: + subfield_id (str): The ID of the subfield to retrieve. + + Raises: + NotFoundException: If the subfield with the specified ID is not found. + + Returns: + Subfield: The subfield matching the provided ID. + """ + subfield = await get_subfield_by_id(subfield_id) + if subfield is None: + raise NotFoundException(f"Subfield with ID {subfield_id} not found.") + return subfield + + async def get_topics_by_ids(topic_ids: list[str]) -> TopicPageV2: """Retrieves topics based on a list of topic IDs. diff --git a/webapp/src/app/api/api/topicsV2.service.ts b/webapp/src/app/api/api/topicsV2.service.ts index 674c4906..4f378585 100644 --- a/webapp/src/app/api/api/topicsV2.service.ts +++ b/webapp/src/app/api/api/topicsV2.service.ts @@ -1,7 +1,7 @@ /** * Innovation Search Engine API * - * + * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -9,18 +9,30 @@ */ /* tslint:disable:no-unused-variable member-ordering */ -import { Inject, Injectable, Optional } from '@angular/core'; -import { HttpClient, HttpHeaders, HttpParams, - HttpResponse, HttpEvent, HttpParameterCodec, HttpContext - } from '@angular/common/http'; -import { CustomHttpParameterCodec } from '../encoder'; -import { Observable } from 'rxjs'; +import { Inject, Injectable, Optional } from '@angular/core'; +import { + HttpClient, + HttpHeaders, + HttpParams, + HttpResponse, + HttpEvent, + HttpParameterCodec, + HttpContext, +} from '@angular/common/http'; +import { CustomHttpParameterCodec } from '../encoder'; +import { Observable } from 'rxjs'; +// @ts-ignore +import { Domain } from '../model/domain'; // @ts-ignore import { HTTPValidationError } from '../model/hTTPValidationError'; // @ts-ignore +import { ModelField } from '../model/modelField'; +// @ts-ignore import { SortDirection } from '../model/sortDirection'; // @ts-ignore +import { Subfield } from '../model/subfield'; +// @ts-ignore import { Topic } from '../model/topic'; // @ts-ignore import { TopicPageV2 } from '../model/topicPageV2'; @@ -28,261 +40,779 @@ import { TopicPageV2 } from '../model/topicPageV2'; import { TopicSortBy } from '../model/topicSortBy'; // @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables'; -import { Configuration } from '../configuration'; +import { BASE_PATH, COLLECTION_FORMATS } from '../variables'; +import { Configuration } from '../configuration'; import { BaseService } from '../api.base.service'; - - @Injectable({ - providedIn: 'root' + providedIn: 'root', }) export class TopicsV2Service extends BaseService { + constructor( + protected httpClient: HttpClient, + @Optional() @Inject(BASE_PATH) basePath: string | string[], + @Optional() configuration?: Configuration, + ) { + super(basePath, configuration); + } - constructor(protected httpClient: HttpClient, @Optional() @Inject(BASE_PATH) basePath: string|string[], @Optional() configuration?: Configuration) { - super(basePath, configuration); + /** + * Returns a paginated list of topics for a given search term based on their display name. + * @endpoint get /api/topics/v2/autocomplete/selector + * @param query A search term to filter topics by (partial matches allowed). + * @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 autocompleteTopicsForSelector( + query?: string, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public autocompleteTopicsForSelector( + query?: string, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public autocompleteTopicsForSelector( + query?: string, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public autocompleteTopicsForSelector( + query?: string, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + let localVarQueryParameters = new HttpParams({ encoder: this.encoder }); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + query, + 'query', + ); + + let localVarHeaders = this.defaultHeaders; + + const localVarHttpHeaderAcceptSelected: string | undefined = + options?.httpHeaderAccept ?? + this.configuration.selectHeaderAccept(['application/json']); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set( + 'Accept', + localVarHttpHeaderAcceptSelected, + ); } - /** - * Returns a paginated list of topics for a given search term based on their display name. - * @endpoint get /api/topics/v2/autocomplete/selector - * @param query A search term to filter topics by (partial matches allowed). - * @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 autocompleteTopicsForSelector(query?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable; - public autocompleteTopicsForSelector(query?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public autocompleteTopicsForSelector(query?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public autocompleteTopicsForSelector(query?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable { + const localVarHttpContext: HttpContext = + options?.context ?? new HttpContext(); - let localVarQueryParameters = new HttpParams({encoder: this.encoder}); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - query, 'query'); + const localVarTransferCache: boolean = options?.transferCache ?? true; - let localVarHeaders = this.defaultHeaders; + 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'; + } + } - const localVarHttpHeaderAcceptSelected: string | undefined = options?.httpHeaderAccept ?? this.configuration.selectHeaderAccept([ - 'application/json' - ]); - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); - } + let localVarPath = `/api/topics/v2/autocomplete/selector`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } - const localVarHttpContext: HttpContext = options?.context ?? new HttpContext(); + /** + * Returns a domain for a given domain ID. + * @endpoint get /api/topics/v2/domains/single/{domain_id} + * @param domainId The ID of the domain to retrieve. + * @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 getDomainById( + domainId: string, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public getDomainById( + domainId: string, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getDomainById( + domainId: string, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getDomainById( + domainId: string, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + if (domainId === null || domainId === undefined) { + throw new Error( + 'Required parameter domainId was null or undefined when calling getDomainById.', + ); + } - const localVarTransferCache: boolean = options?.transferCache ?? true; + let localVarHeaders = this.defaultHeaders; + const localVarHttpHeaderAcceptSelected: string | undefined = + options?.httpHeaderAccept ?? + this.configuration.selectHeaderAccept(['application/json']); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set( + 'Accept', + localVarHttpHeaderAcceptSelected, + ); + } - 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'; - } - } + const localVarHttpContext: HttpContext = + options?.context ?? new HttpContext(); - let localVarPath = `/api/topics/v2/autocomplete/selector`; - const { basePath, withCredentials } = this.configuration; - return this.httpClient.request('get', `${basePath}${localVarPath}`, - { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - ...(withCredentials ? { withCredentials } : {}), - headers: localVarHeaders, - observe: observe, - ...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}), - reportProgress: reportProgress - } + 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 = `/api/topics/v2/domains/single/${this.configuration.encodeParam({ name: 'domainId', value: domainId, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } + + /** + * Returns a field for a given field ID. + * @endpoint get /api/topics/v2/fields/single/{field_id} + * @param fieldId The ID of the field to retrieve. + * @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 getFieldById( + fieldId: string, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public getFieldById( + fieldId: string, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getFieldById( + fieldId: string, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getFieldById( + fieldId: string, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + if (fieldId === null || fieldId === undefined) { + throw new Error( + 'Required parameter fieldId was null or undefined when calling getFieldById.', + ); + } + + 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 = `/api/topics/v2/fields/single/${this.configuration.encodeParam({ name: 'fieldId', value: fieldId, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } + + /** + * Returns a subfield for a given subfield ID. + * @endpoint get /api/topics/v2/subfields/single/{subfield_id} + * @param subfieldId The ID of the subfield to retrieve. + * @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 getSubfieldById( + subfieldId: string, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public getSubfieldById( + subfieldId: string, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getSubfieldById( + subfieldId: string, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getSubfieldById( + subfieldId: string, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + if (subfieldId === null || subfieldId === undefined) { + throw new Error( + 'Required parameter subfieldId was null or undefined when calling getSubfieldById.', + ); + } + + 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 = `/api/topics/v2/subfields/single/${this.configuration.encodeParam({ name: 'subfieldId', value: subfieldId, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } + + /** + * Returns a topic for a given topic ID. + * @endpoint get /api/topics/v2/single/{raw_oa_topic_id} + * @param rawOaTopicId The ID of the topic to retrieve. + * @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 getTopicById( + rawOaTopicId: string, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public getTopicById( + rawOaTopicId: string, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getTopicById( + rawOaTopicId: string, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getTopicById( + rawOaTopicId: string, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + if (rawOaTopicId === null || rawOaTopicId === undefined) { + throw new Error( + 'Required parameter rawOaTopicId was null or undefined when calling getTopicById.', + ); + } + + 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 = `/api/topics/v2/single/${this.configuration.encodeParam({ name: 'rawOaTopicId', value: rawOaTopicId, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request('get', `${basePath}${localVarPath}`, { + context: localVarHttpContext, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }); + } + + /** + * Returns a paginated list of topics for a given list of topic IDs. + * @endpoint get /api/topics/v2/topics/id + * @param topicIds A list of topic IDs to retrieve. + * @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 getTopicsByIds( + topicIds?: Array, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public getTopicsByIds( + topicIds?: Array, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getTopicsByIds( + topicIds?: Array, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public getTopicsByIds( + topicIds?: Array, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + let localVarQueryParameters = new HttpParams({ encoder: this.encoder }); + if (topicIds) { + topicIds.forEach((element) => { + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + element, + 'topic_ids', ); + }); } - /** - * Returns a topic for a given topic ID. - * @endpoint get /api/topics/v2/single/{raw_oa_topic_id} - * @param rawOaTopicId The ID of the topic to retrieve. - * @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 getTopicById(rawOaTopicId: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable; - public getTopicById(rawOaTopicId: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public getTopicById(rawOaTopicId: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public getTopicById(rawOaTopicId: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable { - if (rawOaTopicId === null || rawOaTopicId === undefined) { - throw new Error('Required parameter rawOaTopicId was null or undefined when calling getTopicById.'); - } + let localVarHeaders = this.defaultHeaders; - 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 = `/api/topics/v2/single/${this.configuration.encodeParam({name: "rawOaTopicId", value: rawOaTopicId, in: "path", style: "simple", explode: false, dataType: "string", dataFormat: undefined})}`; - const { basePath, withCredentials } = this.configuration; - return this.httpClient.request('get', `${basePath}${localVarPath}`, - { - context: localVarHttpContext, - responseType: responseType_, - ...(withCredentials ? { withCredentials } : {}), - headers: localVarHeaders, - observe: observe, - ...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}), - reportProgress: reportProgress - } - ); + const localVarHttpHeaderAcceptSelected: string | undefined = + options?.httpHeaderAccept ?? + this.configuration.selectHeaderAccept(['application/json']); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set( + 'Accept', + localVarHttpHeaderAcceptSelected, + ); } - /** - * Returns a paginated list of topics for a given list of topic IDs. - * @endpoint get /api/topics/v2/topics/id - * @param topicIds A list of topic IDs to retrieve. - * @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 getTopicsByIds(topicIds?: Array, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable; - public getTopicsByIds(topicIds?: Array, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public getTopicsByIds(topicIds?: Array, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public getTopicsByIds(topicIds?: Array, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable { + const localVarHttpContext: HttpContext = + options?.context ?? new HttpContext(); - let localVarQueryParameters = new HttpParams({encoder: this.encoder}); - if (topicIds) { - topicIds.forEach((element) => { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - element, 'topic_ids'); - }) - } + const localVarTransferCache: boolean = options?.transferCache ?? true; - 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 = `/api/topics/v2/topics/id`; - const { basePath, withCredentials } = this.configuration; - return this.httpClient.request('get', `${basePath}${localVarPath}`, - { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - ...(withCredentials ? { withCredentials } : {}), - headers: localVarHeaders, - observe: observe, - ...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}), - reportProgress: reportProgress - } - ); + 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'; + } } - /** - * Searches for topics based on the provided criteria. - * @endpoint get /api/topics/v2/search - * @param searchTerm The term to search for in topic display names. - * @param page The page number to retrieve. - * @param size The number of topics to retrieve per page. - * @param sortBy The field to sort by. - * @param sortDirection The direction to sort. - * @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 searchTopics(searchTerm?: string, page?: number, size?: number, sortBy?: TopicSortBy, sortDirection?: SortDirection, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable; - public searchTopics(searchTerm?: string, page?: number, size?: number, sortBy?: TopicSortBy, sortDirection?: SortDirection, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public searchTopics(searchTerm?: string, page?: number, size?: number, sortBy?: TopicSortBy, sortDirection?: SortDirection, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable>; - public searchTopics(searchTerm?: string, page?: number, size?: number, sortBy?: TopicSortBy, sortDirection?: SortDirection, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext, transferCache?: boolean}): Observable { + let localVarPath = `/api/topics/v2/topics/id`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } - let localVarQueryParameters = new HttpParams({encoder: this.encoder}); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - searchTerm, 'search_term'); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - page, 'page'); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - size, 'size'); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - sortBy, 'sort_by'); - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, - sortDirection, 'sort_direction'); + /** + * Searches for topics based on the provided criteria. + * @endpoint get /api/topics/v2/search + * @param searchTerm The term to search for in topic display names. + * @param page The page number to retrieve. + * @param size The number of topics to retrieve per page. + * @param sortBy The field to sort by. + * @param sortDirection The direction to sort. + * @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 searchTopics( + searchTerm?: string, + page?: number, + size?: number, + sortBy?: TopicSortBy, + sortDirection?: SortDirection, + observe?: 'body', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable; + public searchTopics( + searchTerm?: string, + page?: number, + size?: number, + sortBy?: TopicSortBy, + sortDirection?: SortDirection, + observe?: 'response', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public searchTopics( + searchTerm?: string, + page?: number, + size?: number, + sortBy?: TopicSortBy, + sortDirection?: SortDirection, + observe?: 'events', + reportProgress?: boolean, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable>; + public searchTopics( + searchTerm?: string, + page?: number, + size?: number, + sortBy?: TopicSortBy, + sortDirection?: SortDirection, + observe: any = 'body', + reportProgress: boolean = false, + options?: { + httpHeaderAccept?: 'application/json'; + context?: HttpContext; + transferCache?: boolean; + }, + ): Observable { + let localVarQueryParameters = new HttpParams({ encoder: this.encoder }); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + searchTerm, + 'search_term', + ); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + page, + 'page', + ); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + size, + 'size', + ); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + sortBy, + 'sort_by', + ); + localVarQueryParameters = this.addToHttpParams( + localVarQueryParameters, + sortDirection, + 'sort_direction', + ); - let localVarHeaders = this.defaultHeaders; + 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 = `/api/topics/v2/search`; - const { basePath, withCredentials } = this.configuration; - return this.httpClient.request('get', `${basePath}${localVarPath}`, - { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - ...(withCredentials ? { withCredentials } : {}), - headers: localVarHeaders, - observe: observe, - ...(localVarTransferCache !== undefined ? { transferCache: localVarTransferCache } : {}), - reportProgress: reportProgress - } - ); + 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 = `/api/topics/v2/search`; + const { basePath, withCredentials } = this.configuration; + return this.httpClient.request( + 'get', + `${basePath}${localVarPath}`, + { + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: responseType_, + ...(withCredentials ? { withCredentials } : {}), + headers: localVarHeaders, + observe: observe, + ...(localVarTransferCache !== undefined + ? { transferCache: localVarTransferCache } + : {}), + reportProgress: reportProgress, + }, + ); + } } diff --git a/webapp/src/app/api/model/domain.ts b/webapp/src/app/api/model/domain.ts new file mode 100644 index 00000000..3a6c6b03 --- /dev/null +++ b/webapp/src/app/api/model/domain.ts @@ -0,0 +1,29 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { DomainFieldsInner } from './domainFieldsInner'; +import { DomainIds } from './domainIds'; + +/** + * Top-level category in the topic hierarchy (4 total) + */ +export interface Domain { + id?: string | null; + display_name?: string | null; + description?: string | null; + display_name_alternatives?: Array | null; + fields?: Array | null; + siblings?: Array | null; + ids?: DomainIds | null; + works_count?: number | null; + cited_by_count?: number | null; + works_api_url?: string | null; + created_date?: string | null; + updated_date?: string | null; +} diff --git a/webapp/src/app/api/model/domainFieldsInner.ts b/webapp/src/app/api/model/domainFieldsInner.ts new file mode 100644 index 00000000..302feae8 --- /dev/null +++ b/webapp/src/app/api/model/domainFieldsInner.ts @@ -0,0 +1,17 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +/** + * DomainFieldsInner + */ +export interface DomainFieldsInner { + id?: string | null; + display_name?: string | null; +} diff --git a/webapp/src/app/api/model/domainIds.ts b/webapp/src/app/api/model/domainIds.ts new file mode 100644 index 00000000..da44d258 --- /dev/null +++ b/webapp/src/app/api/model/domainIds.ts @@ -0,0 +1,18 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +/** + * External identifiers: + */ +export interface DomainIds { + openalex?: string | null; + wikidata?: string | null; + wikipedia?: string | null; +} diff --git a/webapp/src/app/api/model/modelField.ts b/webapp/src/app/api/model/modelField.ts new file mode 100644 index 00000000..f0aa2203 --- /dev/null +++ b/webapp/src/app/api/model/modelField.ts @@ -0,0 +1,31 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { DomainFieldsInner } from './domainFieldsInner'; +import { DomainIds } from './domainIds'; +import { WorkTopicDomain } from './workTopicDomain'; + +/** + * Second-level category in the topic hierarchy (26 total) + */ +export interface ModelField { + id?: string | null; + display_name?: string | null; + description?: string | null; + display_name_alternatives?: Array | null; + domain?: WorkTopicDomain | null; + subfields?: Array | null; + siblings?: Array | null; + ids?: DomainIds | null; + works_count?: number | null; + cited_by_count?: number | null; + works_api_url?: string | null; + created_date?: string | null; + updated_date?: string | null; +} diff --git a/webapp/src/app/api/model/models.ts b/webapp/src/app/api/model/models.ts index afed834d..ada7aabd 100644 --- a/webapp/src/app/api/model/models.ts +++ b/webapp/src/app/api/model/models.ts @@ -78,6 +78,9 @@ export * from './dfgProjectSummary'; export * from './dfgProjectTopic'; export * from './dfgProjectTopics'; export * from './dockerHealth'; +export * from './domain'; +export * from './domainFieldsInner'; +export * from './domainIds'; export * from './edge'; export * from './euCordisEurosciVocSummary'; export * from './euCordisOrganizationSelectorPage'; @@ -172,6 +175,7 @@ export * from './matchedTopic'; export * from './mentionedPerson'; export * from './meta'; export * from './model2YrMeanCitedness'; +export * from './modelField'; export * from './newsArticle'; export * from './newsArticleDetail'; export * from './newsPage'; @@ -206,6 +210,9 @@ export * from './score'; export * from './selectedAuthorsRequest'; export * from './sortDirection'; export * from './startCollaborationGraphResponse'; +export * from './subfield'; +export * from './subfieldDomain'; +export * from './subfieldField'; export * from './subfieldShare'; export * from './timespan'; export * from './tokenType'; diff --git a/webapp/src/app/api/model/subfield.ts b/webapp/src/app/api/model/subfield.ts new file mode 100644 index 00000000..ef678f6a --- /dev/null +++ b/webapp/src/app/api/model/subfield.ts @@ -0,0 +1,33 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { DomainFieldsInner } from './domainFieldsInner'; +import { DomainIds } from './domainIds'; +import { SubfieldDomain } from './subfieldDomain'; +import { SubfieldField } from './subfieldField'; + +/** + * Third-level category in the topic hierarchy (254 total) + */ +export interface Subfield { + id?: string | null; + display_name?: string | null; + description?: string | null; + display_name_alternatives?: Array | null; + field?: SubfieldField | null; + domain?: SubfieldDomain | null; + topics?: Array | null; + siblings?: Array | null; + ids?: DomainIds | null; + works_count?: number | null; + cited_by_count?: number | null; + works_api_url?: string | null; + created_date?: string | null; + updated_date?: string | null; +} diff --git a/webapp/src/app/api/model/subfieldDomain.ts b/webapp/src/app/api/model/subfieldDomain.ts new file mode 100644 index 00000000..b2228d75 --- /dev/null +++ b/webapp/src/app/api/model/subfieldDomain.ts @@ -0,0 +1,17 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +/** + * The domain containing this subfield (top level of hierarchy). + */ +export interface SubfieldDomain { + id?: string | null; + display_name?: string | null; +} diff --git a/webapp/src/app/api/model/subfieldField.ts b/webapp/src/app/api/model/subfieldField.ts new file mode 100644 index 00000000..8aff75ea --- /dev/null +++ b/webapp/src/app/api/model/subfieldField.ts @@ -0,0 +1,17 @@ +/** + * Innovation Search Engine API + * + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +/** + * The field containing this subfield (parent level). + */ +export interface SubfieldField { + id?: string | null; + display_name?: string | null; +}