zhengyiming
2025-03-03 dfb8f993f691eedc558d52347b1a93a105f6b0d2
packages/core/src/types.ts
@@ -1,14 +1,7 @@
import { AxiosRequestConfig } from 'axios';
import { type RequestConfig } from 'senior-request';
export interface IRequestOptions extends AxiosRequestConfig {}
export interface IRequest {
  <T = any>(url: string, opts: IRequestOptions): Promise<T>;
}
export type BlLifeRechargeServicesOptions<T extends IRequest> = {
  request: T;
  axiosOptions?: AxiosRequestConfig;
export type BlLifeRechargeServicesOptions<TResponse = any, TRequestOptions = any> = {
  axiosConfig?: RequestConfig<TResponse, TRequestOptions>;
};
export type BlLifeRechargeAccountModelOptions = {
@@ -16,5 +9,8 @@
  phoneNumber?: string;
};
export type BlLifeRechargeOptions<T extends IRequest> = BlLifeRechargeServicesOptions<T> &
export type BlLifeRechargeOptions<
  TResponse = any,
  TRequestOptions = any
> = BlLifeRechargeServicesOptions<TResponse, TRequestOptions> &
  BlLifeRechargeAccountModelOptions & {};