how to type-safely pass an argument to useQuery from a previous request? - TanStack