11import { DefaultApi } from '../api/default-api' ;
22import { ProcessApi } from '../api/process-api' ;
3+ import { HealthcheckApi } from '../api/healthcheck-api' ;
34import { TransactionApi } from '../api/transaction-api' ;
45import { Response } from './process-response' ;
56import { Configuration , ConfigurationParameters } from '../configuration' ;
@@ -16,13 +17,15 @@ import {
1617 InlineResponse200 ,
1718 ListTransactionsByTagResponse ,
1819 TransactionProcessGetResponse ,
20+ Healthcheck ,
1921} from '../models' ;
2022import { Base64String , instanceOfProcessRequest , ProcessRequestExt } from './process-request-ext' ;
2123import { ProcessRequestImageWrapper } from './process-request-image-wrapper' ;
2224import * as converter from 'base64-arraybuffer' ;
2325
2426export class DocumentReaderApi {
2527 private readonly defaultApi : DefaultApi ;
28+ private readonly healthcheckApi : HealthcheckApi ;
2629 private readonly processApi : ProcessApi ;
2730 private readonly transactionApi : TransactionApi ;
2831
@@ -34,6 +37,7 @@ export class DocumentReaderApi {
3437 axios : AxiosInstance = globalAxios ,
3538 ) {
3639 this . defaultApi = new DefaultApi ( new Configuration ( configuration ) , basePath , axios ) ;
40+ this . healthcheckApi = new HealthcheckApi ( new Configuration ( configuration ) , basePath , axios ) ;
3741 this . processApi = new ProcessApi ( new Configuration ( configuration ) , basePath , axios ) ;
3842 this . transactionApi = new TransactionApi ( new Configuration ( configuration ) , basePath , axios ) ;
3943 }
@@ -43,6 +47,11 @@ export class DocumentReaderApi {
4347 return axiosResult . data ;
4448 }
4549
50+ async health ( xRequestID ?: string ) : Promise < Healthcheck > {
51+ const axiosResult = await this . healthcheckApi . healthz ( xRequestID ) ;
52+ return axiosResult . data ;
53+ }
54+
4655 /**
4756 *
4857 * @summary Process list of documents images and return extracted data
0 commit comments