Skip to content

app.expense_receipts

TableRow level security on

The receipt photo of an expense, filed from Compass with the expense (Section 4.3 item 11). Written only by app.submit_expense_receipt; readable by whoever can read the expense.

Primary key: id

Columns of app.expense_receipts
ColumnTypeNullableDescription
iduuidNoPrimary key, UUID v7.
org_iduuidNoOwning org, derived from app.expenses on insert; never accepted from the caller and never changed.References app.organizations.id
expense_iduuidNoThe expense the receipt belongs to.References app.expenses.id
media_uritextNoObject name of the photo in the field-media bucket: <org_id>/expense-receipts/<project_id>/<file name>, the project of the expense's budget line.
capture_sourcetextNoHow the photo was taken: Camera (Compass's camera) or Photo Library (one photo picked in the system picker).
captured_attimestamp with time zoneYesWhen the photo was taken, by the device clock; null when unknown.
ai_suggestion_iduuidYesThe Aurora receipt extraction whose proposed fields the person confirmed, or null when they typed every field.References app.ai_suggestions.id
created_attimestamp with time zoneNoWhen the row was inserted. Set by the database.
created_byuuidYesPerson who inserted the row, or null for a platform process. Set by the database.References app.people.id
updated_attimestamp with time zoneNoWhen the row last changed. Set by the database.
updated_byuuidYesPerson who last changed the row, or null for a platform process. Set by the database.References app.people.id
deleted_attimestamp with time zoneYesSoft delete time. A row with deleted_at set is ignored by every access helper.