diff --git a/blockchain_integration/pi_network/pi_network_university/payment_gateway/schemas.py b/blockchain_integration/pi_network/pi_network_university/payment_gateway/schemas.py new file mode 100644 index 000000000..1cb2f99ad --- /dev/null +++ b/blockchain_integration/pi_network/pi_network_university/payment_gateway/schemas.py @@ -0,0 +1,20 @@ +# payment_gateway/schemas.py +from. import ma +from.models import User, PaymentMethod, Transaction + +class UserSchema(ma.SQLAlchemyAutoSchema): + class Meta: + model = User + load_instance = True + exclude = ("password",) + +class PaymentMethodSchema(ma.SQLAlchemyAutoSchema): + class Meta: + model = PaymentMethod + load_instance = True + exclude = ("payment_method_token",) + +class TransactionSchema(ma.SQLAlchemyAutoSchema): + class Meta: + model = Transaction + load_instance = True