code: def archive(self, repo_slug=None, format='zip', prefix=''):
          
          prefix = '%s'.lstrip('/') % prefix
          self._get_files_in_dir(repo_slug=repo_slug, dir='/')
          if self.bitbucket.repo_tree:
              with NamedTemporaryFile(delete=False) as archive:
                  with ZipFile(archive, 'w') as zip_archive:
                      for name, file in self.bitbucket.repo_tree.items():
                          with NamedTemporaryFile(delete=False) as temp_file:
                              temp_file.write(file.encode('utf-8'))
                          zip_archive.write(temp_file.name, prefix + name)
              return (True, archive.name)
          return (False, 'Could not archive your project.')
docs: Get one of your repositories and compress it as an archive.
              Return the path of the archive.
  
              format parameter is curently not supported.