1👍
✅
You forgot the request parameter of your function:
def getMyMessages(request):
from django_mailbox.models import Message
qs = Message.objects.all()
count = 0
for i in qs:
count += 1
output = output + str(count)+ " " + i.text +'<br>' + '<br>'
return HttpResponse(output)
Source:stackexchange.com