diff --git a/src/fastify.ts b/src/fastify.ts index 8ea186b..90b5893 100644 --- a/src/fastify.ts +++ b/src/fastify.ts @@ -5,21 +5,29 @@ export type ServiceResult = { successful: boolean; }; -export abstract class Client { +export abstract class BaseClient { private axiosInstance: AxiosInstance; constructor(axiosInstance: AxiosInstance) { this.axiosInstance = axiosInstance; } + + getAxios(): AxiosInstance { + return this.axiosInstance; + } } -export abstract class Service { +export abstract class BaseService { private client: T; constructor(client: T) { this.client = client; } + getClient(): T { + return this.client; + } + getSuccessfulResult(result: R): ServiceResult { return { result,