Skip to content

v0.3.0 — freeform client fields and a payee

Latest

Choose a tag to compare

@ralyodio ralyodio released this 29 Aug 08:00
7e20aeb

Clients keep the fields your business actually keeps

A client had columns and nothing else. Now it also has whatever you put on it:

billing client add "Acme Inc", https://acme.com, +1-555-0100
billing client add acme --contact.telephone +1-555-0100 --contact.name Jane
billing client payee acme solana:9xQe...

The comma form is what you paste out of an email signature — the first segment
is the name and the rest are recognised by shape, in any order, because
nobody's signature comes in a fixed one. A segment nothing recognises is kept as
a note rather than dropped: losing a line somebody pasted is worse than filing
it imprecisely.

Any dotted flag sets that path. --billing.po works because it says what it
means, so there is no field list to be missing from. Setting one path merges
with what is there and never drops the rest. An undotted unknown flag is still
an error — freeform fields must not turn every typo into a silently accepted
field.

A payee, recorded rather than guessed

payee is where a client's payments land. A bare address with no chain:
prefix and no --chain is filed as unknown rather than assumed, and
client payee acme with no address is refused rather than clearing the one
already there — a typo must not silently change where money goes.

invoice render --format json carries it, which is how an outside payment rail
asks where to settle.

Why this release exists

It is the half that had to exist before moshcode's /client could move out
here. moshcode kept contact details this way; this model could not, so migrating
a client would have dropped every field nobody predicted — and a lossy migration
is one nobody should run. billing import now carries the lot: every key with
no column here travels as-is, and the columns that do exist are not duplicated
into fields.

Also: setPath refuses __proto__, constructor and prototype. These paths
come straight off a command line, so --__proto__.x is a field called
__proto__, not a write to Object.prototype.

129 tests. First release published by CI rather than by hand.