Add portable field metadata and typed person attributes - #535
Add portable field metadata and typed person attributes#535salmonumbrella wants to merge 1 commit into
Conversation
roborev: Combined Review (
|
15e8a4d to
69feb99
Compare
|
Fixed in
The PR remains one commit. |
roborev: Combined Review (
|
69feb99 to
43f836f
Compare
|
Fixed in
The PR remains one commit. |
roborev: Combined Review (
|
43f836f to
24630e3
Compare
|
Fixed in amended head 24630e3: shared subsets now exclude person attribute definitions and values by default; --include-attributes explicitly includes current and historical values and emits a sensitive-data warning. Explicit --expected-value-id values below 1 are rejected before any API request, while valid IDs are forwarded. Record-reference widgets now require a matching target, so organization widgets are rejected until organization targets are supported. |
roborev: Combined Review (
|
24630e3 to
c8d111e
Compare
|
Fixed in c8d111e. Non-record-reference values now reject either record field, and the request-level regression covers stray record_type and record_id as 400 responses. |
roborev: Combined Review (
|
Add a registry-backed custom-field model and typed historized person values across SQLite and PostgreSQL, with provenance, supersession, CAS, and dry-run support. Expose the model through HTTP, generated clients, and CLI workflows while keeping field creation free of runtime DDL.
c8d111e to
a2316eb
Compare
|
Resolved in |
roborev: Combined Review (
|
What changed
primary_channel,contact_frequency,ask_me_about, and the read-only derivedlast_contacted.Why
A JSON-only profile blob cannot preserve independently addressable values with their own provenance, confidence, actor, ordinal, and active interval. Typed value rows retain that history and keep current-value lookups indexable.
Dynamic per-user DDL would require migration, synchronization, permission, and API machinery for every custom field. Metadata rows plus concrete typed tables keep field creation portable across SQLite and PostgreSQL without issuing runtime DDL.
This is the second implementation slice in #534.
Usage
msgvault attribute-definition list --object-type personmsgvault attribute-definition create --definition @field.jsonmsgvault person attributes set <person-id> ask_me_about --value sailingmsgvault person attributes list <person-id> --history