Skip to content

Commit ce6feb3

Browse files
committed
duplicate timeRange
1 parent 293c0fc commit ce6feb3

File tree

2 files changed

+30
-2
lines changed

2 files changed

+30
-2
lines changed

specs/recommend/common/schemas/RecommendRule.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ RecommendRule:
2828
type: array
2929
description: Time periods when the rule is active.
3030
items:
31-
$ref: '../../../common/schemas/Rule.yml#/timeRange'
31+
$ref: '#/timeRange'
3232

3333
Condition:
3434
type: object
@@ -123,3 +123,17 @@ AutoFacetFilter:
123123
Whether the filter is negative.
124124
If true, recommendations must not have the same value for the `facet` attribute.
125125
If false, recommendations must have the same value for the `facet` attribute.
126+
127+
timeRange:
128+
type: object
129+
additionalProperties: false
130+
properties:
131+
from:
132+
type: integer
133+
description: When the rule should start to be active, in Unix epoch time.
134+
until:
135+
type: integer
136+
description: When the rule should stop to be active, in Unix epoch time.
137+
required:
138+
- from
139+
- until

specs/search/paths/rules/common/schemas.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ rule:
3030
type: array
3131
description: Time periods when the rule is active.
3232
items:
33-
$ref: '../../../../common/schemas/Rule.yml#/timeRange'
33+
$ref: '#/timeRange'
3434
required:
3535
- objectID
3636

@@ -289,6 +289,20 @@ automaticFacetFilter:
289289
required:
290290
- facet
291291

292+
timeRange:
293+
type: object
294+
additionalProperties: false
295+
properties:
296+
from:
297+
type: integer
298+
description: When the rule should start to be active, in Unix epoch time.
299+
until:
300+
type: integer
301+
description: When the rule should stop to be active, in Unix epoch time.
302+
required:
303+
- from
304+
- until
305+
292306
updatedRuleResponse:
293307
type: object
294308
additionalProperties: false

0 commit comments

Comments
 (0)