26 lines
452 B
Python
26 lines
452 B
Python
from typing import List, Literal
|
|
|
|
from pydantic import BaseModel
|
|
|
|
|
|
class CollectionEntry(BaseModel):
|
|
locations: List[int]
|
|
garbage_type: Literal[0, 1, 2, 3, 4, 5]
|
|
date: str
|
|
|
|
|
|
class Location(BaseModel):
|
|
id: int
|
|
name: str
|
|
location: List[int]
|
|
country: int
|
|
timezone: str
|
|
|
|
|
|
class SearchResultsCollectionEntry(BaseModel):
|
|
results: List[CollectionEntry]
|
|
|
|
|
|
class SearchResultsLocation(BaseModel):
|
|
results: List[Location]
|