Models
Data models used throughout the API. All models use UUID identifiers and include timestamps.
Dataset
Microdata file metadata
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
name | string | Human-readable name |
description | string | null | Optional description |
filepath | string | Path in storage bucket |
year | integer | Simulation year |
tax_benefit_model_version_id | UUID | Associated model version |
created_at | datetime | Creation timestamp |
Policy
Parameter reform definition
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
name | string | Policy name |
description | string | null | Optional description |
parameter_values | ParameterValue[] | Parameter modifications |
created_at | datetime | Creation timestamp |
ParameterValue
Single parameter modification
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
parameter_id | UUID | Reference to parameter |
value_json | object | New parameter value |
start_date | date | Effective start date |
end_date | date | Effective end date |
Simulation
Tax-benefit microsimulation run
| Field | Type | Description |
|---|---|---|
id | UUID | Deterministic identifier |
dataset_id | UUID | Input dataset |
tax_benefit_model_version_id | UUID | Model version |
policy_id | UUID | null | Optional reform policy |
dynamic_id | UUID | null | Optional behavioural model |
status | SimulationStatus | Processing status |
error_message | string | null | Error if failed |
started_at | datetime | null | Processing start time |
completed_at | datetime | null | Processing end time |
Report
Economic impact analysis container
| Field | Type | Description |
|---|---|---|
id | UUID | Deterministic identifier |
label | string | Human-readable label |
baseline_simulation_id | UUID | Baseline simulation |
reform_simulation_id | UUID | Reform simulation |
status | ReportStatus | Processing status |
error_message | string | null | Error if failed |
created_at | datetime | Creation timestamp |
DecileImpact
Distributional impact by income decile
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
report_id | UUID | Parent report |
decile | integer | Income decile (1-10) |
income_variable | string | Variable for ranking |
baseline_mean | number | Baseline mean income |
reform_mean | number | Reform mean income |
absolute_change | number | Absolute difference |
relative_change | number | Percentage change |
count_better_off | number | Winners count |
count_worse_off | number | Losers count |
count_no_change | number | No change count |
ProgramStatistics
Tax/benefit program impact statistics
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
report_id | UUID | Parent report |
program_name | string | Program name |
entity | string | Entity level |
is_tax | boolean | True for taxes |
baseline_total | number | Baseline total |
reform_total | number | Reform total |
change | number | Difference |
baseline_count | number | Baseline recipients |
reform_count | number | Reform recipients |
winners | number | Winners count |
losers | number | Losers count |
AggregateOutput
Computed aggregate statistic
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier |
simulation_id | UUID | Source simulation |
variable | string | Variable name |
aggregate_type | AggregateType | Calculation type |
entity | string | Entity level |
filter_config | object | null | Optional filter |
result | number | Computed value |