@app.route('/v1/repositories/<path:repository>/', methods=['DELETE'])
@app.route('/v1/repositories/<path:repository>/tags', methods=['DELETE'])
@toolkit.parse_repository_name
@toolkit.requires_auth
def delete_repository(namespace, repository):
 logger.debug('[delete_repository] namespace={0}; repository={1}'.format(namespace, repository))
 try:
  for (tag_name, tag_content) in get_tags(namespace=namespace, repository=repository).items():
   delete_tag(namespace=namespace, repository=repository, tag=tag_name)
  store.remove(store.repository_path(namespace=namespace, repository=repository))
 except exceptions.FileNotFoundError:
  return toolkit.api_error('Repository not found', 404)
 else:
  sender = flask.current_app._get_current_object()
  signals.repository_deleted.send(sender, namespace=namespace, repository=repository)
 return toolkit.response()

@ app . route ( '/v1/repositories/<path:repository>/' , methods = [ 'DELETE' ] ) @ app . route ( '/v1/repositories/<path:repository>/tags' , methods = [ 'DELETE' ] ) @ toolkit . parse_repository_name @ toolkit . requires_auth def delete_repository ( namespace , repository ) : logger . debug ( '[delete_repository] namespace={0}; repository={1}' . format ( namespace , repository ) ) try : for ( tag_name , tag_content ) in get_tags ( namespace = namespace , repository = repository ) . items ( ) : delete_tag ( namespace = namespace , repository = repository , tag = tag_name ) store . remove ( store . repository_path ( namespace = namespace , repository = repository ) ) except exceptions . FileNotFoundError : return toolkit . api_error ( 'Repository not found' , 404 ) else : sender = flask . current_app . _get_current_object ( ) signals . repository_deleted . send ( sender , namespace = namespace , repository = repository ) return toolkit . response ( )
remove a repository from storage this endpoint exists in both the registry api [1] and the indexer api [2] .