Try this:
w = 2500.mm d = 2000.mm h = 1000.mm pts = [[0,0,h-40.mm], [w,0,h-40.mm], [w,d,h-40.mm], [0,d,h-40.mm]] group = Sketchup.active_model.entities.add_group container = group.entities ; base = container.add_face pts h = -h if base.normal.dot(Z_AXIS) < 0.0 base.pushpull 40.mm group.material = "red" ;Todd