Command for creating an object of custom size The default command when creating a cube at the origin is the following:

bpy.ops.mesh.primitive_cube_add(view_align=False, enter_editmode=False, location=(0.0, 0.0, 0.0), rotation=(0, 0, 0), layers=(True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False))


since I am not bothered about rotations and layers I can keep only the location like so:

bpy.ops.mesh.primitive_cube_add(location=(0.0, 0.0, 0.0))


This creates a UNIT cube at the origin (0,0,0).

My question is: Is there a way to add the dimensions of the cube I want, within that line somehow? 

I am not asking about using a scale command after creating it... but rather creating it in the desired size straight away...?
Yes, you can use radius

bpy.ops.mesh.primitive_cube_add(location=(0.0, 0.0, 0.0), radius=2)


See the documentation for more details.

radius in this case is the half of the cubes edge length, so

bpy.ops.mesh.primitive_cube_add(location=(0.0, 0.0, 0.0), radius=edgelen/2)


would build a cube with edge length of edgelen.

Answer uses the Python API of Blender 2.72