class NetworkMemberSerializer(serializers.Serializer): id = serializers.CharField(help_text="Network member id") type = serializers.ChoiceField( help_text=FabricNodeType.get_info("Node Types:", list_str=True), choices=FabricNodeType.to_choices(True), ) url = serializers.CharField(help_text="URL of member")
class NodeCreateBody(serializers.Serializer): network_type = serializers.ChoiceField( help_text=NetworkType.get_info("Network types:", list_str=True), choices=NetworkType.to_choices(True), ) type = serializers.ChoiceField( help_text=FabricNodeType.get_info("Node Types:", list_str=True), choices=FabricNodeType.to_choices(True), )