2023-06-09 14:16:42 +00:00
|
|
|
{
|
|
|
|
"title": "A registration form",
|
|
|
|
"description": "A simple form example.",
|
|
|
|
"type": "object",
|
|
|
|
"required": [
|
|
|
|
"firstName",
|
2023-06-12 22:06:43 +00:00
|
|
|
"lastName",
|
|
|
|
"age",
|
|
|
|
"bio",
|
|
|
|
"telephone"
|
2023-06-09 14:16:42 +00:00
|
|
|
],
|
|
|
|
"properties": {
|
|
|
|
"firstName": {
|
|
|
|
"type": "string",
|
|
|
|
"title": "First name",
|
|
|
|
"default": "Chuck"
|
|
|
|
},
|
|
|
|
"lastName": {
|
|
|
|
"type": "string",
|
2023-06-12 22:06:43 +00:00
|
|
|
"title": "Last name",
|
|
|
|
"default": "Norris"
|
2023-06-09 14:16:42 +00:00
|
|
|
},
|
|
|
|
"age": {
|
|
|
|
"type": "integer",
|
2023-06-12 22:06:43 +00:00
|
|
|
"title": "Age",
|
|
|
|
"default": 83,
|
|
|
|
"minimum": 18,
|
|
|
|
"maximum": 130
|
2023-06-09 14:16:42 +00:00
|
|
|
},
|
|
|
|
"bio": {
|
|
|
|
"type": "string",
|
2023-06-12 22:06:43 +00:00
|
|
|
"title": "Bio",
|
|
|
|
"default": "Chuck Norris was once bitten by a poisonous snake. And after a week of excruciating pain, the snake died.",
|
|
|
|
"minLength": 10
|
2023-06-09 14:16:42 +00:00
|
|
|
},
|
|
|
|
"telephone": {
|
|
|
|
"type": "string",
|
|
|
|
"title": "Telephone",
|
2023-06-12 22:06:43 +00:00
|
|
|
"pattern": "^(\\+\\d{1,2}\\s)?\\(?\\d{3}\\)?[\\s.-]\\d{3}[\\s.-]\\d{4}$",
|
|
|
|
"validationErrorMessage": "Please provide a valid phone number, for example: +91 (123) 456-7890 or +1 540-555-1234",
|
|
|
|
"default": "1-800-kick-ass"
|
2023-06-09 14:16:42 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|