import type { paths } from '@/shared/api/schema'; import { api } from '@/shared/api/client'; type IncomeListPath = paths['/incomes/list/{id}']['get']['parameters']['path']; type IncomeListResponse = paths['/incomes/list/{id}']['get']['responses']['200']['content']['application/json']; export async function getIncomeList(path: IncomeListPath) { const { data: result } = await api.get(`/incomes/list/${path.id}`); return result; }