Added collection validation
This commit is contained in:
parent
24a2837f34
commit
4a2e15c6e7
24
validation/users.json
Normal file
24
validation/users.json
Normal file
@ -0,0 +1,24 @@
|
||||
{
|
||||
"$jsonSchema": {
|
||||
"required": [
|
||||
"id",
|
||||
"locale"
|
||||
],
|
||||
"properties": {
|
||||
"user": {
|
||||
"bsonType": [
|
||||
"int",
|
||||
"long"
|
||||
],
|
||||
"description": "Telegram ID of user"
|
||||
},
|
||||
"locale": {
|
||||
"bsonType": [
|
||||
"string",
|
||||
"null"
|
||||
],
|
||||
"description": "Preferred messages language according to "
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user