Example: https://stackblitz.com/edit/vitejs-vite-mygi8omd?file=src%2Fmain.ts
All client function return type are unknown instead of the AxiosPromise<T> type.
const rbacApi = APIFactory('/', {
getPrincipalAccess,
});
// This is unknown but should be GetPrincipalAccessReturnType
const resp = rbacApi.getPrincipalAccess({
application: 'foo',
limit: 123,
});
The resp is of type unknown which means TS will not let you access the Promise API. You have to type cast the return value or ignore the TS.