PCG, Get index of points on the spline and loop them for pathfinding through them

Hi, I want to create a PCG spline system to sample my spline, get the controls point (ora point along the spline, that’s not a problem) then I want to take the index of these points to create a pathfinding.
Basically I would have a pathfinding for each couple of point index from the spline.
I think this would involve using PCG loop o loopFeedback but unfortunately i didn’t find the correct way.
In the image the current system where i can get the first and the second point, but they are hard coded so not procedural for each point.

These points feed a pcg loop for the pathfinding, but i don’t think it’s the right way.

I might have taken the wrong approach, because using pathfinding for each pair ends up giving me a broken spline at the connection points. What I’d like is for the pathfinding to use my spline as a guideline and then do its job: how can I achieve this?