ignore folder
This commit is contained in:
8
services/tenant.ts
Normal file
8
services/tenant.ts
Normal file
@ -0,0 +1,8 @@
|
||||
import { ApiResponse, TenantContextResponse } from "@/types/api";
|
||||
import { apiClient } from "./api";
|
||||
|
||||
export async function getTenantContext(): Promise<TenantContextResponse> {
|
||||
const response = await apiClient.get<ApiResponse<TenantContextResponse>>("/api/tenant/context");
|
||||
if (!response.data.success) throw new Error(response.data.message);
|
||||
return response.data.data;
|
||||
}
|
||||
Reference in New Issue
Block a user