This repository has been archived on 2024-05-31. You can view files and clone it, but cannot push or open issues or pull requests.
authentik/passbook/sources/saml/api.py
2019-12-31 12:51:16 +01:00

29 lines
643 B
Python

"""SAMLSource API Views"""
from rest_framework.serializers import ModelSerializer
from rest_framework.viewsets import ModelViewSet
from passbook.sources.saml.models import SAMLSource
class SAMLSourceSerializer(ModelSerializer):
"""SAMLSource Serializer"""
class Meta:
model = SAMLSource
fields = [
"pk",
"entity_id",
"idp_url",
"idp_logout_url",
"auto_logout",
"signing_cert",
]
class SAMLSourceViewSet(ModelViewSet):
"""SAMLSource Viewset"""
queryset = SAMLSource.objects.all()
serializer_class = SAMLSourceSerializer