code: def _build_regular_workflow(json_spec):
      
      workflow_id = dxpy.api.workflow_new(json_spec)["id"]
      dxpy.api.workflow_close(workflow_id)
      return workflow_id
docs: Precondition: json_spec must be validated