You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Schema: models + GET/PUT /api/lists/{id}/schema service #17
ListFieldVisibility — Condition { Field, Operator, Value }.
ListFieldType — the twelve types as a constrained set: text, textarea, number, boolean, date, datetime, email, url, tel, select, multiselect, priority.
Note the wire mapping: each fields[] entry is stored as a ListProperty (key→propertyKey, label→propertyName, type→propertyType) — the properties body shape uses those names.
Service
GetListSchemaAsync(listId) → GET, response is wrapped: {"data": {...}}.
CreateListAsync gains an optional schema argument.
Error handling
400 responses name the offending column, e.g. Invalid schema: Field 'year' has invalid type 'integer'. Valid types: text, number, ...
Surface that message against the field, not as a generic failure. Also handle: missing name, empty fields, a field missing key/type/label, select/multiselect without options, duplicate keys.
Acceptance criteria
All four service methods land, shapes verified live against the test account.
ListSummary keeps compiling; schema is fetched separately, not folded into it.
A round-trip test (read schema → PUT it back unchanged) is verified on a throwaway test list.
Implemented in #143 — work continues in the PR from here.
Three surprises worth carrying into #18-#22. First, the non-destructive properties form accepts only six propertyTypes (text, number, boolean, date, url, email) and propertyType is mandatory on every item, so a list using any of the other six DSL types can't be re-shaped non-destructively at all — ListSchema.SupportsPropertiesEdit exposes that so the UI can route around it. Second, "destructive" turns out to mean columns, not rows: the DSL rebuild drops and recreates every column with a new id and overwrites the list title and description (clearing the description when omitted), but the rows survive with values for removed keys orphaned in rowData — so #22's confirmation copy should say that, not "rows will be deleted". Third, deleting a data-bearing column via properties is refused with a 409 carrying propertiesWithData: [...] until you re-send with ?force=true (which strips the key from every row); the shared EnsureSuccessAsync would have thrown that array away, hence the dedicated ListSchemaException.
Confirmed on throwaway lists (all deleted): properties preserves rows byte-for-byte, and schema.name does overwrite the list title. Also: /help/api/lists still documents the DSL as a string — that form is rejected, object only.
Activity
Adron commentedon Sep 16, 2026
Implemented in #143 — work continues in the PR from here.
Three surprises worth carrying into #18-#22. First, the non-destructive
propertiesform accepts only six propertyTypes (text, number, boolean, date, url, email) andpropertyTypeis mandatory on every item, so a list using any of the other six DSL types can't be re-shaped non-destructively at all —ListSchema.SupportsPropertiesEditexposes that so the UI can route around it. Second, "destructive" turns out to mean columns, not rows: the DSL rebuild drops and recreates every column with a new id and overwrites the list title and description (clearing the description when omitted), but the rows survive with values for removed keys orphaned inrowData— so #22's confirmation copy should say that, not "rows will be deleted". Third, deleting a data-bearing column viapropertiesis refused with a409carryingpropertiesWithData: [...]until you re-send with?force=true(which strips the key from every row); the sharedEnsureSuccessAsyncwould have thrown that array away, hence the dedicatedListSchemaException.Confirmed on throwaway lists (all deleted):
propertiespreserves rows byte-for-byte, andschema.namedoes overwrite the list title. Also:/help/api/listsstill documents the DSL as a string — that form is rejected, object only.Merge pull request #143 from CompositeCode/issue-17-list-schema-service