fix(api): ensure openapi spec has deprecated routes

This commit is contained in:
Ashwin Bharambe 2025-11-13 12:25:36 -08:00
parent 840ad75fe9
commit 10e71386ba
3 changed files with 744 additions and 2 deletions

View file

@ -979,8 +979,8 @@ class Generator:
if deprecated:
filtered_operations.append(op)
elif self.options.stability_filter == "stainless":
# Include both stable (v1 non-deprecated) and experimental (v1alpha, v1beta) endpoints
if (stability_level == "v1" and not deprecated) or stability_level in ["v1alpha", "v1beta"]:
# Include stable (v1), deprecated (v1 deprecated), and experimental (v1alpha, v1beta) endpoints
if stability_level == "v1" or stability_level in ["v1alpha", "v1beta"]:
filtered_operations.append(op)
operations = filtered_operations