Files
varsity/test/schemas/payment-method-schema.json
2025-10-01 20:01:42 +00:00

36 lines
730 B
JSON

{
"type": "object",
"required": ["type", "details"],
"properties": {
"type": {
"type": "string",
"enum": ["credit_card", "debit_card", "paypal", "bank_transfer"]
},
"details": {
"type": "object",
"properties": {
"cardNumber": {
"type": "string",
"pattern": "^[0-9]{13,19}$"
},
"expiryMonth": {
"type": "integer",
"minimum": 1,
"maximum": 12
},
"expiryYear": {
"type": "integer",
"minimum": 2024
},
"cvv": {
"type": "string",
"pattern": "^[0-9]{3,4}$"
},
"accountId": {
"type": "string"
}
}
}
}
}