You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
352 B
11 lines
352 B
from rest_framework import serializers
|
|
|
|
|
|
class ExchangeTokenSerializer(serializers.Serializer):
|
|
temp_token = serializers.CharField(max_length=128)
|
|
|
|
def validate_temp_token(self, value: str) -> str:
|
|
value = value.strip()
|
|
if not value:
|
|
raise serializers.ValidationError("temp_token is required.")
|
|
return value
|