here is a curve, maybe it's generated by NURBS, or it's generated by intersection of 2 surfaces

now I need to export a series of points on the curve to

[[x0, y0, z0], [x1, y1, z1],...]

is there any API can do this? please help me.

also, if I want to modify the resolution of the points, how to do it?