from django.http import HttpResponseRedirect
from django.core.urlresolvers import reverse

def myview(request):
    passwords_url = reverse('passwords_api_root')
return HttpResponseRedirect(passwords_url)
Django, name parameter in urlpatterns