Bevel with specified radius in python script
Assuming you have a bezier curve with only 2 control points and you always want a circle for your shape, you can do this. I think this works, its past my bedtime, but copy paste in the text editor and it should work. Feel free to expand on your wishes.
import bpy

bpy.ops.curve.primitive_bezier_curve_add()
curve = bpy.context.active_object 

curve.data.use_fill_caps = True 
curve.data.bevel_mode = 'ROUND'     # Gives it a circle shape without needing another object as a profile.
curve.data.bevel_depth = 1          # 1 Meter Radius (NOT DIAMETER)

# These will multipy the curve radius at each control point, 
# so best to keep that at 1m and control the taper with these.
start_radius = 0.1  # Radius Multiplier 1
end_radius   = 0.3  # Radius Multiplier 2

# Assuming the curve type is 'BEZIER'
curve_points = curve.data.splines[0].bezier_points

# Assuming your curve only has 2 points.
curve_points[0].radius = start_radius
curve_points[1].radius = end_radius