+ tl;dr - Overly complex use of postgres DOMAIN and composite TYPEs (with CASTing to jsonb) used to support the better-than-naive definition of a price as a currency + natural number. For actual production usage do yourself and your team a favor and use a currency type column + integer for amount (ex. cents in USD). For those who like hacking I also got TypeORM to read/work with the composite TYPE with even more dirty dirty hacks.