Draw cylinder from pos1 to pos2

Hello,

In the Python API there is a function to draw cylinders “Mesh.Primitives.cylinder()” but I can’t place the cylinder where I want.

Has anyone written a function that tranlates & rotates the newly created
cylinder so that is fall between:

pos1 = x1, y1, z1
pos2 = x2, y2, z2

Many thank for your help and suggestions.

Emmanuel