code: def upload(cls, file_path, progressbar=None):
          
          res = cls._resource
          doc_id = upload_document(file_path, res._client.session, res, progressbar=progressbar)
  
          return cls.get(doc_id)
docs: Uploads a series of files to the One Codex server.
  
          Parameters
          ----------
          file_path : `string`
              A path to a file on the system.
          progressbar : `click.progressbar`, optional
              If passed, display a progress bar using Click.
  
          Returns
          -------
          A `Samples` object upon successful upload. None if the upload failed.