You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: ctf/templates/init/schemas/post.json
+20-47Lines changed: 20 additions & 47 deletions
Original file line number
Diff line number
Diff line change
@@ -26,15 +26,9 @@
26
26
"type": "string",
27
27
"enum": [
28
28
"flag",
29
-
"multiFlag",
30
29
"score",
31
30
"timer"
32
31
]
33
-
},
34
-
"tag": {
35
-
"description": "Value of the trigger. For a flag trigger, this is the flag value.",
36
-
"type": "string",
37
-
"minLength": 1
38
32
}
39
33
},
40
34
"required": [
@@ -50,9 +44,17 @@
50
44
"then": {
51
45
"properties": {
52
46
"tag": {
53
-
"description": "Discourse tag of the flag to trigger on.",
54
-
"type": "string",
47
+
"description": "Discourse tags of the flags to trigger on.",
48
+
"type": ["string", "array"],
49
+
"items": {
50
+
"type": "string",
51
+
"minLength": 1
52
+
},
55
53
"minLength": 1
54
+
},
55
+
"threshold": {
56
+
"description": "Number of relevant flags required for the multiFlag trigger. Ex: If this is set to 2, the trigger will only fire if 2 or more of the tags in the `tags` list are present.",
57
+
"type": "number"
56
58
}
57
59
},
58
60
"required": [
@@ -64,66 +66,37 @@
64
66
"if": {
65
67
"properties": {
66
68
"type": {
67
-
"const": "multiFlag"
69
+
"const": "score"
68
70
}
69
71
}
70
72
},
71
73
"then": {
72
-
"properties": {
73
-
"tags": {
74
-
"description": "List of discourse tags of relevant flags.",
75
-
"type": "array",
76
-
"items": {
77
-
"type": "string",
78
-
"minLength": 1
79
-
}
80
-
},
81
-
"threshold": {
82
-
"description": "Number of relevant flags required for the multiFlag trigger. Ex: If this is set to 2, the trigger will only fire if 2 or more of the tags in the `tags` list are present.",
83
-
"type": "number"
84
-
}
74
+
"value": {
75
+
"description": "Value of the score trigger. Ex: If this is set to 10, the trigger will only fire if the user's score is 10 or more.",
76
+
"type": "number"
85
77
},
86
78
"required": [
87
79
"type",
88
-
"tags"
80
+
"value"
89
81
]
90
82
},
91
83
"else": {
92
84
"if": {
93
85
"properties": {
94
86
"type": {
95
-
"const": "score"
87
+
"const": "timer"
96
88
}
97
89
}
98
90
},
99
91
"then": {
100
-
"value": {
101
-
"description": "Value of the score trigger. Ex: If this is set to 10, the trigger will only fire if the user's score is 10 or more.",
102
-
"type": "number"
92
+
"after": {
93
+
"description": "Time at which to trigger. The layout of this string is \"2006/01/02 15:04\"",
94
+
"type": "string"
103
95
},
104
96
"required": [
105
97
"type",
106
-
"value"
98
+
"after"
107
99
]
108
-
},
109
-
"else": {
110
-
"if": {
111
-
"properties": {
112
-
"type": {
113
-
"const": "timer"
114
-
}
115
-
}
116
-
},
117
-
"then": {
118
-
"after": {
119
-
"description": "Time at which to trigger. The layout of this string is \"2006/01/02 15:04\"",
0 commit comments