2021-04-10 16:09:22 +02:00

16 lines
350 B
Python

import logging
from django.http import JsonResponse
from rest_framework.decorators import api_view
logger = logging.getLogger(__name__)
class TestApiClass:
@staticmethod
@api_view(['GET'])
def test_api(request):
logger.debug('Test api call: {}'.format(request))
return JsonResponse({'Result': 'success'}, safe=False)