generated from coulomb/repo-seed
Implement canonical schema foundation
This commit is contained in:
42
schemas/check_request.schema.json
Normal file
42
schemas/check_request.schema.json
Normal file
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://flex-auth.netkingdom/schemas/check_request.schema.json",
|
||||
"title": "CheckRequest",
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": ["subject", "action", "resource"],
|
||||
"properties": {
|
||||
"id": {"type": "string", "minLength": 1},
|
||||
"subject": {"$ref": "#/$defs/subject_ref"},
|
||||
"action": {"type": "string", "minLength": 1},
|
||||
"resource": {"$ref": "#/$defs/resource_ref"},
|
||||
"context": {"type": "object", "additionalProperties": true},
|
||||
"caring_context": {"$ref": "https://flex-auth.netkingdom/schemas/caring_access_descriptor.schema.json"},
|
||||
"policy_version": {"type": "string", "minLength": 1}
|
||||
},
|
||||
"$defs": {
|
||||
"subject_ref": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": ["id"],
|
||||
"properties": {
|
||||
"id": {"type": "string", "minLength": 1},
|
||||
"type": {"$ref": "https://flex-auth.netkingdom/schemas/caring_access_descriptor.schema.json#/$defs/subject_type"},
|
||||
"tenant": {"type": "string", "minLength": 1},
|
||||
"attributes": {"type": "object", "additionalProperties": true}
|
||||
}
|
||||
},
|
||||
"resource_ref": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": ["id"],
|
||||
"properties": {
|
||||
"id": {"type": "string", "minLength": 1},
|
||||
"type": {"type": "string", "minLength": 1},
|
||||
"system": {"type": "string", "minLength": 1},
|
||||
"tenant": {"type": "string", "minLength": 1},
|
||||
"attributes": {"type": "object", "additionalProperties": true}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user