OpenAPI Specs do not match API Endpoints - specifically around Nested Object Counts #17985
Labels
status: duplicate
This issue has already been raised
type: bug
A confirmed report of unexpected behavior in the application
Deployment Type
Self-hosted
Triage priority
N/A
NetBox Version
v4.0.11
Python Version
3.11
Steps to Reproduce
Related Issues
#16670
#16085
To Replicate:
devicetype_count
Expected Behavior
Expected Response according to Swagger / Specs
Includes devicetype_count
Observed Behavior
Actual Endpoint Response
(missing devicetype_count)
Impact: Generated OpenAPI Models use this schema, and fail to process data correctly, since that field is expected to exist.
Other Nested Models also observed as affected
This might be separate issues, but the other Github issues linked several together around nested serialization. If I'm beyond the scope, let me know and I can remove these from the issue report, but I felt it may be worth documenting that this is bigger than just a single model. It may be more than these below.
The root cause of this seems to affects other models:
BriefDeviceType
Query - /dcim/device-types/281/
Note the schema - devicetype_count
Note the missing devicetype_count field.
BriefDeviceRole
When it is returned as part of a Nested object, notice the missing count fields that should be on the schema.
The text was updated successfully, but these errors were encountered: