import { ConfigService } from '@nestjs/config'; import { LabBooksBook } from 'itlab-functions'; import { AuthenticationModuleOptions } from '../../../authentication'; import { BaseHttpService } from '../../base-http.service'; import { FetchBookOptionsDtoV1 } from './fetch-book-options.dto.v1.type'; /** * BooksService * * Service client responsible for interacting with the Books microservice. * Extends `BaseHttpService` to inherit: * - Environment-sensitive URL resolution (internal vs. external). * - Secure inter-service authentication. * - Structured logging for traceability of outbound requests. * * Why this pattern? * - Ensures all outbound calls follow a unified configuration and logging structure. * - Promotes strong typing and maintainable HTTP logic. * - Makes service interactions predictable and debuggable across environments. */ export declare class BooksService extends BaseHttpService { /** * Constructs an Books service client instance. * * @param {AuthenticationModuleOptions} authenticationOptions - Injected authentication configuration. * @param {ConfigService} configService - NestJS ConfigService for environment detection. */ constructor(authenticationOptions: AuthenticationModuleOptions, configService: ConfigService); /** * Retrieves a single book entry by its MongoDB identifier. * * This method gracefully handles downstream failures by logging * and returning `undefined` instead of throwing. * * @param {string} bookId - Unique MongoDB identifier of the book. * @param {FetchBookOptionsDtoV1} [options] - Optional query parameters for filtering or projection. * @returns {Promise} Resolves to an Book or `undefined` on failure. */ fetchBookV1(bookId: string, options?: FetchBookOptionsDtoV1): Promise; /** * Retrieves a collection of book entries. * * Useful for batch lookups or paginated listings. * Returns an empty array if the downstream service call fails. * * @param {FetchBookOptionsDtoV1} [options] - Optional filter options for narrowing results. * @returns {Promise} Resolves to a list of books, or an empty array if none found. */ fetchBookCollectionV1(options?: FetchBookOptionsDtoV1): Promise; }