Validating a Firebase Key [duplicate]
问题 This question already has answers here : Validate a Firebase Key is an integer (2 answers) Closed 4 years ago . I am just getting started with Firebase security and probably I am missing something. I need to validate that after 'notification' the path(key) is 15 (later I will update 15 to be regex using matching method, but currently I am struggling enforcing this simple case): { "rules": { ".write": true, "notifications": { "$year": { ".validate": "newData.val() === '/15'", } } } } I am