/* eslint-disable */ /* Code generated by ng-openapi-gen DO NOT EDIT. */ import { HttpClient, HttpContext } from '@angular/common/http'; import { Injectable } from '@angular/core'; import { firstValueFrom } from 'rxjs'; import { BaseService } from '../base-service'; import { ApiConfiguration } from '../api-configuration'; import { StrictHttpResponse } from '../strict-http-response'; import { GetHelloResponse } from '../models/get-hello-response'; import { getHello } from '../fn/misc/get-hello'; import { GetHello$Params } from '../fn/misc/get-hello'; @Injectable({ providedIn: 'root' }) export class MiscService extends BaseService { constructor(config: ApiConfiguration, http: HttpClient) { super(config, http); } /** Path part for operation `getHello()` */ static readonly GetHelloPath = '/hello'; /** * Say Hello. * * Returns a friendly hello message. * * This method provides access to the full `HttpResponse`, allowing access to response headers. * To access only the response body, use `getHello()` instead. * * This method doesn't expect any request body. */ getHello$Response(params?: GetHello$Params, context?: HttpContext): Promise> { const obs = getHello(this.http, this.rootUrl, params, context); return firstValueFrom(obs); } /** * Say Hello. * * Returns a friendly hello message. * * This method provides access only to the response body. * To access the full response (for headers, for example), `getHello$Response()` instead. * * This method doesn't expect any request body. */ getHello(params?: GetHello$Params, context?: HttpContext): Promise { const resp = this.getHello$Response(params, context); return resp.then((r: StrictHttpResponse): GetHelloResponse => r.body); } }