diff --git a/oas/2.0/agencies.yaml b/oas/2.0/agencies.yaml index 6621ef56c..bb163440b 100644 --- a/oas/2.0/agencies.yaml +++ b/oas/2.0/agencies.yaml @@ -62,14 +62,14 @@ paths: parameters: - name: "agency_uid" in: "path" - description: "The id of the agency you want to retrieve." + description: "The uid of the agency you want to retrieve." required: true schema: type: "string" get: summary: "Get Agency" operationId: "getAgency" - description: "Get a single agency by id." + description: "Get a single agency by uid." tags: - Agencies responses: @@ -105,7 +105,7 @@ paths: parameters: - name: "agency_uid" in: "path" - description: "The id of the agency you want to retrieve." + description: "The uid of the agency you want to retrieve." required: true schema: type: "string" @@ -156,7 +156,7 @@ paths: parameters: - name: "agency_uid" in: "path" - description: "The id of the agency you want to retrieve." + description: "The uid of the agency you want to retrieve." required: true schema: type: "string" @@ -201,13 +201,13 @@ paths: parameters: - name: "agency_uid" in: "path" - description: "The id of the agency you want to retrieve." + description: "The uid of the agency you want to retrieve." required: true schema: type: "string" - name: "unit_uid" in: "path" - description: "The id of the agency you want to retrieve." + description: "The uid of the agency you want to retrieve." required: true schema: type: "string" @@ -221,7 +221,7 @@ paths: parameters: - name: "agency_uid" in: "path" - description: "The id of the agency you want to retrieve units for." + description: "The uid of the agency you want to retrieve units for." required: true schema: type: "string" @@ -264,7 +264,7 @@ components: BaseAgency: type: "object" properties: - id: + uid: type: "string" description: "Unique identifier for the agency" name: @@ -322,7 +322,7 @@ components: - $ref: "#/components/schemas/BaseAgency" - type: "object" properties: - id: + uid: type: "string" description: "Unique identifier for the agency" officers_url: @@ -373,7 +373,7 @@ components: - $ref: "#/components/schemas/BaseUnit" - type: "object" properties: - id: + uid: type: "string" description: "Unique identifier for the unit" agency_url: @@ -399,7 +399,7 @@ components: properties: officer_uid: type: "string" - description: "The id of the officer" + description: "The uid of the officer" earliest_employment: type: "string" format: "date" @@ -434,7 +434,7 @@ components: properties: officer_uid: type: "string" - description: "The id of the officer" + description: "The uid of the officer" reason: type: "string" description: "The reason the employment record could not be added" diff --git a/oas/pydantic/agencies.py b/oas/pydantic/agencies.py index 7beabdcc9..06a9ca9d0 100644 --- a/oas/pydantic/agencies.py +++ b/oas/pydantic/agencies.py @@ -3,7 +3,7 @@ class BaseAgency(BaseModel): - id: Optional[str] = Field(None, description="Unique identifier for the agency") + uid: Optional[str] = Field(None, description="Unique identifier for the agency") name: Optional[str] = Field(None, description="Name of the agency") hq_address: Optional[str] = Field(None, description="Address of the agency") hq_city: Optional[str] = Field(None, description="City of the agency") @@ -16,7 +16,7 @@ class BaseAgency(BaseModel): class CreateAgency(BaseAgency, BaseModel): - id: Optional[str] = Field(None, description="Unique identifier for the agency") + uid: Optional[str] = Field(None, description="Unique identifier for the agency") name: Optional[str] = Field(None, description="Name of the agency") hq_address: Optional[str] = Field(None, description="Address of the agency") hq_city: Optional[str] = Field(None, description="City of the agency") @@ -29,7 +29,7 @@ class CreateAgency(BaseAgency, BaseModel): class UpdateAgency(BaseAgency, BaseModel): - id: Optional[str] = Field(None, description="Unique identifier for the agency") + uid: Optional[str] = Field(None, description="Unique identifier for the agency") name: Optional[str] = Field(None, description="Name of the agency") hq_address: Optional[str] = Field(None, description="Address of the agency") hq_city: Optional[str] = Field(None, description="City of the agency") @@ -46,7 +46,7 @@ class AgencyList(PaginatedResponse, BaseModel): class Agency(BaseAgency, BaseModel): - id: Optional[str] = Field(None, description="Unique identifier for the agency") + uid: Optional[str] = Field(None, description="Unique identifier for the agency") name: Optional[str] = Field(None, description="Name of the agency") hq_address: Optional[str] = Field(None, description="Address of the agency") hq_city: Optional[str] = Field(None, description="City of the agency") @@ -103,7 +103,7 @@ class Unit(BaseUnit, BaseModel): address: Optional[str] = Field(None, description="Street address of the unit") zip: Optional[str] = Field(None, description="Zip code of the unit") commander: Optional[str] = Field(None, description="The Officer UID of the unit's commander") - id: Optional[str] = Field(None, description="Unique identifier for the unit") + uid: Optional[str] = Field(None, description="Unique identifier for the unit") agency_url: Optional[str] = Field(None, description="URL to get the agency that this unit belongs to.") officers_url: Optional[str] = Field(None, description="URL to get a list of officers for this unit.") @@ -113,7 +113,7 @@ class UnitList(PaginatedResponse, BaseModel): class AddOfficer(BaseModel): - officer_uid: str = Field(..., description="The id of the officer") + officer_uid: str = Field(..., description="The uid of the officer") earliest_employment: Optional[str] = Field(None, description="The earliest date of employment") latest_employment: Optional[str] = Field(None, description="The latest date of employment") badge_number: str = Field(..., description="The badge number of the officer") @@ -127,7 +127,7 @@ class AddOfficerList(BaseModel): class AddOfficerFailed(BaseModel): - officer_uid: Optional[str] = Field(None, description="The id of the officer") + officer_uid: Optional[str] = Field(None, description="The uid of the officer") reason: Optional[str] = Field(None, description="The reason the employment record could not be added")