afterhours-shift-manager/.redocly.yaml
Cursor Agent 166f2de029
fix(api): document 4xx and treat 302 as success in Redocly (DEV-289)
Health and CORS preflight document 400. Recommended only counted 2XX,
so login-style 302s use a shared 2XX-or-3XX rule.

Co-authored-by: Adam Moussa <amoussa1229@users.noreply.github.com>
2026-09-21 23:56:04 +00:00

29 lines
616 B
YAML

# Same Redocly recommended ruleset as internal-portal (DEV-223 / DEV-289).
# Login-style redirects succeed with 302. Recommended only counts 2XX.
extends:
- recommended
rules:
operation-2xx-response: off
rule/operation-2xx-or-3xx-response:
subject:
type: Responses
message: Operation must define a 2XX or 3XX response.
severity: warn
assertions:
requireAny:
- "200"
- "201"
- "202"
- "204"
- "301"
- "302"
- "303"
- "307"
- "308"
- "2XX"
- "3XX"
apis:
afterhours@v1:
root: openapi.yaml