Add GET /companies browse/discover endpoint
CI / lint (push) Canceled after 0s
CI / typecheck (push) Canceled after 0s
CI / unit-tests (push) Canceled after 0s
CI / integration-tests (push) Canceled after 0s
CI / container-build (push) Canceled after 0s
CI / dependency-audit (push) Canceled after 0s

Completes the browse/discover set across all four entity types.
Companies have no popularity or date field, so unlike movies/series/
people there's no sort_by choice -- always alphabetical by name.
Filters are company_type (validated against the enum) and country
(a plain ISO 3166-1 code comparison, nothing to validate).

build_company_summary refactored to share row-to-summary logic with
the new list path, same pattern used for movies/series/people.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
This commit is contained in:
NixReaper
2026-09-05 19:08:14 -05:00
co-authored by Claude Sonnet 5
parent 6aa9f0b840
commit 92b0f4e077
6 changed files with 227 additions and 12 deletions
+9
View File
@@ -6,6 +6,7 @@ from datetime import datetime
from pydantic import BaseModel
from app.schemas.common import CompanyBriefOut
from app.schemas.movie import MovieSummaryOut
from app.schemas.tv import SeriesSummaryOut
@@ -28,3 +29,11 @@ class CompanyDetailOut(BaseModel):
created_at: datetime
updated_at: datetime
class CompanyListOut(BaseModel):
page: int
page_size: int
total_results: int
total_pages: int
results: list[CompanyBriefOut] = []