# Generated by web/scripts/semantics.mjs from semantics/catalog.yaml. Do not edit.
apiVersion: v3.0.2
kind: DataContract
id: wardrobe-diary-garment-history
name: Garment history
version: 0.2.1
status: active
domain: wardrobe-diary
dataProduct: The Wardrobe Diary Project
description:
  purpose: Every saved version of every garment (an audit trail), including the version before each change.
  usage: Not public (owner-only); described for transparency.
team:
  - username: hoverfalt
    name: Olof Hoverfält
    role: owner
servers:
  - server: garment-history
    type: custom
    description: Firestore users/{uid}/garments/{garmentId}/history/{autoId}
schema:
  - name: garment-history
    physicalName: Firestore users/{uid}/garments/{garmentId}/history/{autoId}
    logicalType: object
    description: Every saved version of every garment (an audit trail), including the version before each change.
    properties:
      - name: savedAt
        logicalType: date
        physicalType: timestamp
        required: true
        description: When the version was saved.
      - name: before
        logicalType: object
        physicalType: garment
        required: false
        description: The previous version; empty when the garment was created in the app.
      - name: after
        logicalType: object
        physicalType: garment
        required: true
        description: The saved version.
      - name: note
        logicalType: string
        physicalType: text
        required: false
        description: What happened, e.g. "Photo replaced".
slaProperties:
  - property: frequency
    value: daily (logged in the app)
authoritativeDefinitions:
  - type: catalog
    url: https://wardrobediary.io/data#garment-history
