code: public function purgeIndex()
      {
          $endpoints = $this->endpointResolver->getEndpoints();
  
          foreach ($endpoints as $endpointName) {
              $this->purgeEndpoint(
                  $this->endpointRegistry->getEndpoint($endpointName)
              );
          }
      }
docs: @todo implement purging for document type
  
  Purges all contents from the index