Capabilities for no framework · stable
Ordered by level: primitives at the bottom of the graph, workflows at the top. Each one carries its own tests, at least 8 per function.
Suites — the capabilities a kind of app is built from: accounting, payroll, an online shop, a clinic…
Collection: React form elements — accessible form components for React, and the pure helpers they use.
Level 0 primitive
math.exp
e to the power x from + - * / only, so TypeScript, Python and Rust return the same double for the same input.
exp in TypeScript
math.sin-cos
Sine and cosine of an angle in radians from + - * / only, so every language returns the same doubles.
sinCos in TypeScript
validation.uk-company-number
Check a Companies House company number's format and prefix (SC, NI, OC, LP...) and zero-pad it to eight characters.
validateUkCompanyNumber in TypeScript
validation.uk-utr
Check an HMRC Unique Taxpayer Reference's modulus 11 check digit, accepting the K and spacing people type.
validateUkUtr in TypeScript
charts.extent
The minimum and maximum of a series as [min, max], skipping gaps (null), or null when there is no value.
extent in TypeScript
charts.color
Hex colours to RGB and back, and sRGB channels to linear light and back, identically in every language.
A group of 4:
parseHex, toHex, srgbToLinear, linearToSrgb
education.academic-year
The academic year and term a date falls in: 1 September to 31 August by default, terms from the caller.
academicYear in TypeScript
geo.bounding-box
Latitude/longitude bounding box that contains every point within a distance of a centre point.
boundingBox in TypeScript
logistics.sscc
Build an 18-digit SSCC pallet label number from extension digit, GS1 company prefix and serial, with its check digit.
buildSscc in TypeScript
stats.percentile
Percentile of a list of numbers by a named method: nearest-rank, or linear interpolation (R-7, Excel PERCENTILE.INC).
percentile in TypeScript
validation.gtin
Check an EAN-8, UPC-A, EAN-13 or GTIN-14 barcode number against the GS1 mod-10 check digit.
validateGtin in TypeScript
geo.distance
Great-circle distance in metres between two latitude/longitude points (haversine), to the millimetre.
distance in TypeScript
collections.chunk
Split a list into consecutive batches of at most n items, in order; the last batch may be short.
chunk in TypeScript
crypto.constant-time-equal
Compare two byte strings in time that does not depend on where they differ, for checking MACs and hashes.
constantTimeEqual in TypeScript
crypto.hmac-sha256
HMAC-SHA256 of a message under a secret key (RFC 2104, RFC 4231), in pure code that also runs in the browser.
hmacSha256 in TypeScript
crypto.pbkdf2-sha256
PBKDF2 with HMAC-SHA256 (RFC 8018): derive a key from a password and salt, slowly, fast enough for a login request.
pbkdf2Sha256 in TypeScript
crypto.sha256
The SHA-256 digest of a byte string (FIPS 180-4), in pure code that also runs in the browser.
sha256 in TypeScript
dates.add-months
Add calendar months to an ISO date, clamping to the month end: 31 Jan + 1 month is 28 or 29 Feb.
addMonths in TypeScript
dates.overlap
Days two date ranges have in common, with the end of each range stated as inclusive or exclusive.
overlapDays in TypeScript
dates.quarter
Calendar quarter and fiscal quarter of a date, with the fiscal year and quarter date ranges, for any start month.
quarter in TypeScript
encoding.base64
Bytes to base64 and base64url text and back (RFC 4648), with strict decoding, identically in every language.
A group of 4:
base64Encode, base64Decode, base64UrlEncode, base64UrlDecode
encoding.hex
Bytes to lowercase hexadecimal text and back (RFC 4648 base16), strictly, identically in every language.
A group of 2:
hexEncode, hexDecode
encoding.utf8
Text to UTF-8 bytes and strictly back (RFC 3629), so hashing and signing see the same bytes in every language.
A group of 2:
utf8Encode, utf8Decode
geo.point-in-polygon
Whether a latitude/longitude point lies inside a polygon (ray casting; the boundary counts as inside).
pointInPolygon in TypeScript
math.atan
Arctangent in radians from + - * / only (fdlibm's method), so every language returns the same double.
atan in TypeScript
math.basis-points
Convert a rate between percent, basis points and a plain ratio exactly, as decimal text or integer basis points.
A group of 3:
convertRate, toBasisPoints, fromBasisPoints
math.big-integer
Exact integer arithmetic of any size, on decimal strings, for powers and products that overflow 64 bits.
calculateBigInteger in TypeScript
math.clamp
Clamp an integer to an inclusive range, refusing a range whose bounds are the wrong way round.
clamp in TypeScript
math.integer-sqrt
Exact integer square root: the largest whole number whose square does not exceed n.
integerSqrt in TypeScript
math.ln
Natural logarithm from + - * / only, so TypeScript, Python and Rust return the same double for the same input.
ln in TypeScript
math.pow
base to the power exponent from + - * / only, exact by squaring for whole exponents, identical in every language.
pow in TypeScript
math.round-div
Integer division with an explicit rounding mode, for money arithmetic that must not drift.
roundDiv in TypeScript
math.round-float
Round a float half away from zero to 0-12 decimal places, identically in TypeScript, Python and Rust.
roundFloat in TypeScript
monitor.cert-expiry
How long a TLS certificate has left before its notAfter, and whether that is ok, a warning, critical or expired.
certExpiry in TypeScript
monitor.format-duration
A number of seconds as a short human duration for dashboards and alerts: "3h 12m", "2d 4h", "45s".
formatDuration in TypeScript
monitor.maintenance-window
The scheduled maintenance window in force at a moment, if any, so alerts and uptime can be suppressed during it.
activeMaintenance in TypeScript
monitor.series-window
The samples of a time series from one moment up to (not including) another, checking they are in time order.
seriesWindow in TypeScript
subscriptions.trial-end
When a free trial ends and the first payment is due, from the trial's start date and length in days.
trialEnd in TypeScript
text.format-decimal
Format a float as plain decimal text with fixed or trimmed places and optional grouping, identically in every language.
formatDecimal in TypeScript
text.initials
Initials from a personal name for avatars and signatures: "Jean-Paul Sartre" is "JPS".
initials in TypeScript
text.mask
Mask all but the last n characters of a card, account or phone number, optionally keeping separators.
mask in TypeScript
text.normalise-name
Tidy a personal name: trim, collapse whitespace and title-case, with Mc, Mac, O', hyphen and van/de rules.
normaliseName in TypeScript
time.countdown
Seconds left until a Unix time, whether it has passed, and a timer text like 4:05, for tokens or retry waits.
countdown in TypeScript
time.duration
Parse durations written as 1h30m, 90m or 01:30, add them up in whole minutes, and format the total.
duration in TypeScript
time.iso-to-unix
An RFC 3339 timestamp with a Z or offset, such as 2026-09-26T13:00:00+01:00, to Unix time in whole seconds.
isoToUnix in TypeScript
validation.bic
Check the format of a SWIFT/BIC code (8 or 11 characters) and split it into its parts.
validateBic in TypeScript
validation.isbn
Check an ISBN-10 or ISBN-13 and convert between them; the normalised form is always the ISBN-13.
validateIsbn in TypeScript
validation.lei
Check a 20-character Legal Entity Identifier against its ISO 17442 / ISO 7064 MOD 97-10 check digits.
validateLei in TypeScript
validation.vin
Check a 17-character vehicle identification number and its check digit; enforced for North American VINs.
validateVin in TypeScript
charts.contrast
WCAG 2.x contrast ratio between two colours, and which text colour reads best on a background.
A group of 2:
contrastRatio, readableTextColorLevel 1 generic concept
charity.gift-aid-eligibility
Whether a UK donation qualifies for Gift Aid: declaration, enough tax paid, and the donor benefit limits.
giftAidEligibility in TypeScript
banking.faster-payments-limit
Whether a Faster Payment fits the scheme maximum, the bank's per-payment limit and what is left of its daily limit.
fasterPaymentsCheck in TypeScript
charts.scale
Map data values onto screen positions and back: linear, log, time, band and point scales, and nice domains.
A group of 7:
linearScale, invertLinear, niceDomain, logScale, timeScale, bandScale, pointScale
money.add
Add, subtract and negate monetary amounts, refusing to mix currencies.
addMoney in TypeScript
stats.moving-average
Simple or exponential moving average over a series, one value per full window, rounded to stated decimals.
movingAverage in TypeScript
subscriptions.mrr-arr
Monthly and annual recurring revenue from a list of subscriptions, normalising intervals and leaving out trials.
mrrArr in TypeScript
energy.carbon-emissions
kgCO2e from kWh or litres of a fuel, using the UK government GHG conversion factors for the year.
carbonEmissions in TypeScript
form.date-parts
Check a date typed into day, month and year boxes, with GOV.UK's error messages and the boxes to mark in error.
validateDateParts in TypeScript
math.rational
Exact fraction arithmetic, always reduced, for rates and ratios that must not drift.
A group of 8:
calculateRational, rational, addRational, subtractRational, multiplyRational, divideRational, compareRational, rationalToInteger
money.split-even
Split an amount into n near-equal parts that add back up to exactly the whole.
splitEven in TypeScript
retail.coupon-validate
Check a coupon against a basket: dates, usage limits, eligible products and minimum spend, with reason codes.
validateCoupon in TypeScript
stats.standard-deviation
Population or sample standard deviation of a list of numbers, two-pass, rounded to stated decimals.
standardDeviation in TypeScript
fleet.emissions
Vehicle greenhouse gas emissions (grams CO2e) from fuel used or distance, using UK government DESNZ conversion factors.
fleetEmissions in TypeScript
money.compare
Compare two amounts of one currency, refusing to compare across currencies; min, max and clamp too.
A group of 4:
compareMoney, minMoney, maxMoney, clampMoney
validation.nhs-number
Check an NHS number's modulus 11 check digit and normalise it to ten digits.
validateNhsNumber in TypeScript
agri.field-area
Field area in square metres, hectares and acres from a boundary polygon of latitude/longitude points.
fieldArea in TypeScript
agri.growing-degree-days
Growing degree days (thermal time) from daily min/max temperatures, a base and an optional upper cap.
growingDegreeDays in TypeScript
auth.jwt
Sign, verify and decode HS256 JSON Web Tokens (RFC 7519): signature, algorithm and exp/nbf/iat checked with leeway.
A group of 3:
signJwt, verifyJwt, decodeJwt
charity.regular-giving-schedule
Collection dates for a regular gift: monthly, quarterly or annual on a day, clamped to short months, after a lead time.
regularGivingSchedule in TypeScript
charts.downsample
Reduce a long series to a few points that keep its visual shape, by Largest-Triangle-Three-Buckets (LTTB).
downsample in TypeScript
charts.format
Axis and label text for charts: tick numbers, SI prefixes (1.2k, 3.4M), percentages, dates and money.
A group of 5:
formatTick, formatSi, formatPercent, formatDate, formatMoneyTick
charts.histogram-bins
Bin values into histogram bins on round edges, by Sturges' rule, Freedman-Diaconis, or a fixed width.
histogramBins in TypeScript
charts.interpolate-color
The colour at a point along a sequential or diverging ramp, mixed in OKLab so steps look even; hex in, hex out.
interpolateColor in TypeScript
charts.palette
A categorical palette of n colour-blind-safe colours for chart series: Okabe-Ito or Paul Tol's bright scheme.
palette in TypeScript
collections.dedupe-by-key
Remove records that share a key value, keeping the first or the last of each, in input order.
dedupeByKey in TypeScript
collections.diff
Compare two lists of records by key: which were added, which removed, and which changed and in what fields.
diffByKey in TypeScript
collections.group-by-key
Group records by the value at one key, preserving input order inside each group.
groupByKey in TypeScript
collections.paginate
Slice a list into a 1-based page and report the totals an API response needs.
paginate in TypeScript
collections.search-text
Filter records by a case-insensitive substring match across named fields, in input order.
searchText in TypeScript
collections.sort-by
Stably sort records by one key, ascending or descending, with a total order across mixed types.
sortBy in TypeScript
construction.brick-count
Bricks and mortar for a wall, openings subtracted, for UK standard 215 x 102.5 x 65 mm bricks with 10 mm joints.
brickCount in TypeScript
construction.concrete-volume
Concrete for slabs, strip footings, pads and round columns: volume to the litre and an order rounded up to 0.1 m³.
concreteVolume in TypeScript
construction.materials-area
Packs of tiles, paint, plasterboard or flooring to cover an area, with waste and coats, rounded up to whole packs.
materialsArea in TypeScript
construction.roof-pitch
Roof pitch in degrees, rafter length and roof slope area from span, rise and length.
roofPitch in TypeScript
dates.age
Age in whole years on a given date, with 29 February birthdays ageing on 1 March in other years.
age in TypeScript
education.attendance-rate
Pupil attendance and absence rates in basis points, with the DfE persistent and severe absence flags.
attendanceRate in TypeScript
education.degree-classification
UK honours degree class (First, 2:1, 2:2, Third) from module marks and credits, weighted by level.
degreeClassification in TypeScript
energy.degree-days
Heating and cooling degree days from daily mean temperatures and a base temperature, exact to 0.1.
degreeDays in TypeScript
energy.meter-advance
Units consumed between two meter reads, counting the meter rolling over past all nines once.
meterAdvance in TypeScript
finance.ledger.journal-validate
Check a double-entry journal: debits equal credits, no zero or two-sided lines, one currency, well-formed account codes.
validateJournal in TypeScript
finance.payment-terms-due-date
Invoice due date from payment terms: net N days, end of month, N days after month end, day N of next month.
paymentDueDate in TypeScript
fleet.cost-per-mile
Whole-life cost per mile of a vehicle, in tenths of a penny, from depreciation, fuel, maintenance, insurance and tax.
costPerMile in TypeScript
fleet.ev-charging-cost
Cost of an electric vehicle charge from the energy added, charger efficiency and power, and time-of-use tariff windows.
evChargingCost in TypeScript
fleet.fuel-cost
Fuel cost of a trip from distance, fuel economy (UK or US mpg, or L/100km) and price per litre, exactly.
fuelCost in TypeScript
hr.absence-bradford-factor
Bradford factor for a set of absence spells: spells squared times total days, which weights frequent short absences.
bradfordFactor in TypeScript
http.retry-after
Seconds to wait from an HTTP Retry-After header (delay-seconds or an HTTP date), or null if missing or malformed.
retryAfterSeconds in TypeScript
inventory.pallet-fit
How many cartons fit per layer and per pallet (UK 1200x1000 or EUR 1200x800), within a height and weight limit.
palletFit in TypeScript
inventory.reorder-point
Reorder point: demand over the supplier lead time, rounded up to whole units, plus safety stock.
reorderPoint in TypeScript
manufacturing.batch-size
Economic batch quantity: the EOQ for a batch made at a finite production rate, in whole units.
economicBatchQuantity in TypeScript
manufacturing.takt-time
Takt time: available production time divided by customer demand, exact and in whole seconds.
taktTime in TypeScript
manufacturing.yield-scrap
Whole units to start for a required good output at a process yield, and the scrap that allows for.
inputForYield in TypeScript
money.allocate
Split an amount across ratios without losing or inventing a single minor unit.
allocate in TypeScript
money.apply-rate
Apply a rate expressed in basis points to a monetary amount, with an explicit rounding mode.
applyRate in TypeScript
money.parse
Parse "£1,234.50" or "1.234,50 €" into integer minor units, strictly: no guessing, no rounding.
parseMoney in TypeScript
money.sum
Total a list of monetary amounts, with an explicit currency for the empty case.
sumMoney in TypeScript
monitor.burn-rate
How fast an SLO's error budget is burning: the error rate as a multiple of the rate the SLO allows, in thousandths.
burnRate in TypeScript
monitor.error-budget
How much of an SLO's error budget is allowed, used and left, from good and bad event counts or seconds.
errorBudget in TypeScript
monitor.parse-access-log
Parse one Apache/NCSA Common or Combined Log Format access log line; null for a line in neither format.
parseAccessLog in TypeScript
monitor.rollup
Aggregate a metric series into fixed time buckets (count, min, max, avg, sum, last), empty buckets included.
rollup in TypeScript
monitor.status-code-summary
Count HTTP status codes by class (1xx to 5xx) and give the server error and client error rates in basis points.
summariseStatusCodes in TypeScript
net.cidr
CIDR blocks: network, broadcast, first and last host, host count, netmask and prefix, and membership.
A group of 5:
cidrInfo, cidrContains, isCidr, prefixToNetmask, netmaskToPrefix
net.ipv4
Parse, format and check dotted-quad IPv4 addresses, refusing leading zeros, octal, hex and short forms.
A group of 3:
parseIpv4, formatIpv4, isIpv4
net.ipv6
Parse IPv6 addresses and write them in RFC 5952 canonical form: lower-case, zeros compressed, IPv4 embedded.
A group of 3:
parseIpv6, formatIpv6, isIpv6
net.mac-address
Validate a MAC address in colon, hyphen, Cisco dot or bare form and normalise it, with multicast and local bits.
validateMacAddress in TypeScript
net.port
Check a TCP/UDP port number and name the IANA service registered on it, with its system/user/dynamic range.
A group of 2:
isPort, portService
professional.utilisation
Billable utilisation and billing, collection and overall realisation rates, in basis points.
utilisationRates in TypeScript
retail.volumetric-weight
Chargeable parcel weight: the greater of actual and volumetric (dimensional) weight, rounded up to a billing step.
chargeableWeight in TypeScript
text.slugify
Turn a title into a lowercase ASCII URL slug, transliterating common accented Latin letters.
slugify in TypeScript
validation.email
Is this a plausible email address? A documented, pragmatic subset of RFC 5322, not the full grammar.
isEmail in TypeScript
validation.uk-modulus-table
Parse Vocalink's VALACDOS.txt and SCSUBTAB.txt into the table UK sort code modulus checking needs.
parseUkModulusTable in TypeScript
agri.seed-rate
Seed rate in kg/ha from target plants per m², thousand-grain weight and expected establishment.
seedRate in TypeScript
agri.stocking-rate
Stocking rate: livestock units and LU per hectare from animal numbers, by a published LU coefficient table.
stockingRate in TypeScript
agri.yield-per-hectare
Crop yield per hectare and per acre from harvested quantity and field area in any area unit, exactly, as decimal text.
yieldPerHectare in TypeScript
auth.bearer-token
The token from an HTTP Authorization header of the form "Bearer <token>" (RFC 6750), or null if it has none.
parseBearerToken in TypeScript
banking.savings-aer
AER (annual equivalent rate) from a gross nominal rate and how often interest is paid, to two decimal places.
savingsAer in TypeScript
charity.donation-matching
Employer match on a donation: a ratio in basis points, limited by a per-donor cap and a programme budget.
donationMatch in TypeScriptLevel 2 domain function
construction.payment-notice-dates
Construction Act default dates: payment due, payment notice, final date for payment and pay-less notice.
paymentNoticeDates in TypeScript
construction.cis-deduction
Construction Industry Scheme deduction (0, 20 or 30%) on the labour part of a subcontractor payment.
cisDeduction in TypeScript
charity.gift-aid
Gift Aid a UK charity can claim on a donation: basic rate tax grossed up, 25p per £1 at 20%.
giftAid in TypeScript
charts.shape
SVG path strings for lines, areas, steps, monotone curves, bars, arcs and pie slices, identical in every language.
A group of 7:
linePath, areaPath, stepPath, monotoneCurve, barRects, arcPath, pieAngles
energy.price-cap
Ofgem energy price cap unit rate and daily standing charge for a fuel and payment method on a date (GB average).
priceCap in TypeScript
validation.uk-postcode
Validate a UK postcode and normalise it to canonical upper case with one space before the inward code.
validateUkPostcode in TypeScript
finance.uk-bank-rate
Bank of England Bank Rate (base rate) in force on a date, from the Bank's official history since 2001.
ukBankRate in TypeScript
logistics.freight-rate
Freight charge from a carrier's dated weight-break tariff for a zone, with the fuel surcharge in force on the ship date.
freightRate in TypeScript
retail.oss-vat
EU distance-selling VAT: which member state's standard rate applies under OSS and the EUR 10,000 threshold, and the VAT.
ossVat in TypeScript
retail.shipping-rate
Delivery charge from a dated rate table by service, zone, chargeable weight and size, with a free-over threshold.
shippingRate in TypeScript
telecoms.roaming-charge
Roaming charges for a trip abroad from a dated tariff table of zones: daily fees, data, calls and texts.
roamingCharge in TypeScript
todo.group-by-due
Split todos into Overdue, Today, Tomorrow, This week, Later, No date and Done sections, in that order.
A group of 2:
groupByDue, groupByDueWithOrder
hospitality.bill-split
Split a restaurant bill evenly, by item or by share, exactly to the penny, with the service charge shared in proportion.
billSplit in TypeScript
agri.fertiliser-application
Fertiliser product rate (kg/ha and total) to meet N, P2O5 and K2O targets from its analysis, limiting nutrient first.
fertiliserApplication in TypeScript
construction.vat-reverse-charge
Whether the UK VAT domestic reverse charge applies to a construction supply, and the invoice wording.
domesticReverseCharge in TypeScript
finance.late-payment-interest
UK statutory late payment interest (8% over Bank Rate) and fixed compensation under the Late Payment Act 1998.
latePaymentInterest in TypeScript
finance.proration
Split an amount into the part used and the part unused over a billing period, losing nothing.
prorate in TypeScript
fleet.mileage-allowance
HMRC approved mileage allowance payments for an employee's own vehicle: tax-free amount, taxable excess or relief.
mileageAllowance in TypeScript
hospitality.tourist-tax
Visitor levy (tourist tax) on an overnight stay: Edinburgh's 5%, Cardiff's per person per night, or a caller's own rule.
touristTax in TypeScript
monitor.burn-rate-alert
Multiwindow, multi-burn-rate SLO alerting: which rules fire, from event counts per window (Google SRE workbook).
burnRateAlert in TypeScript
agri.feed-ration
Ration costing and dry matter intake from each feed's fresh weight, DM % and price per tonne, in exact money.
feedRation in TypeScript
agri.gross-margin
Enterprise gross margin (output less variable costs), in total and per hectare or per head, in exact money.
grossMargin in TypeScript
agri.milk-price
Milk price per litre and payment from a contract's base price, butterfat/protein adjustments and bonuses.
milkPrice in TypeScript
auth.access-token
Issue an API's HS256 access token, read one from an Authorization header, and refuse revoked or superseded ones.
A group of 3:
issueAccessToken, readAccessToken, confirmAccessToken
banking.overdraft-interest
Overdraft interest for a statement period from daily balances, with an interest-free buffer.
overdraftInterest in TypeScript
charity.gasds
Gift Aid Small Donations Scheme top-up for a tax year: the £8,000 limit, the matching rule and community buildings.
gasds in TypeScript
charity.higher-rate-relief
A Gift Aid donor's extra tax relief at higher, intermediate, additional and top rates, by extending the tax bands.
higherRateRelief in TypeScript
charity.payroll-giving
UK Payroll Giving for one pay period: the donation comes off pay before PAYE, and the tax it saves the employee.
payrollGiving in TypeScript
charity.restricted-funds
Allocate charity spending to restricted funds first, then unrestricted funds, never overdrawing a restricted fund.
allocateFundSpend in TypeScript
charts.layout
Chart layout: the plot area inside margins, legend items wrapped into rows, and greedy label collision avoidance.
A group of 3:
plotArea, legendRows, avoidCollisions
charts.stack
Stack several series for stacked bars and areas: on zero, normalised to 100%, or diverging around zero.
stack in TypeScript
construction.retention
Retention held and released on a construction valuation: full rate, half at practical completion, none at the end.
retention in TypeScript
dates.uk-tax-year
The UK personal tax year containing a date: 6 April to 5 April, with HMRC's label.
ukTaxYear in TypeScript
education.student-loan-repayment
A graduate's student or postgraduate loan repayment for a tax year, as Self Assessment works it out.
studentLoanRepayment in TypeScript
education.timetable-clash
Find timetable clashes: overlapping sessions that share a room, a teacher or a student group, in a fixed order.
timetableClashes in TypeScript
energy.estimate-read
Estimate a meter read for a date from the average daily consumption between two earlier reads, with rollover.
estimateRead in TypeScript
energy.tariff-time-of-use
Cost half-hourly consumption against time-of-use rates: Economy 7 windows or Agile-style half-hourly prices.
timeOfUseCost in TypeScript
energy.water-bill
Metered water and sewerage bill from two reads: volumetric charges, return to sewer, standing and surface water charges.
waterBill in TypeScript
finance.fx-revaluation
Unrealised foreign exchange gain or loss on foreign-currency balances revalued at a period-end rate.
fxRevaluation in TypeScript
fleet.vehicle-depreciation
A vehicle's current value from its cost, age and mileage, on retention curves the caller supplies, exactly.
vehicleDepreciation in TypeScript
hospitality.recipe-cost
Cost a recipe and each portion from ingredient quantities, pack sizes and pack prices, allowing for trim and waste.
recipeCost in TypeScript
inventory.abc-classification
ABC classes by annual consumption value (Pareto), with configurable cut-offs such as 80/15/5 and deterministic ties.
abcClassification in TypeScript
inventory.valuation-weighted-average
Perpetual weighted average cost: stock value and cost of sales from a movement ledger, rounding once per issue.
weightedAverageValuation in TypeScript
logistics.container-fit
How many identical cartons fit in a 20ft, 40ft or 40ft high-cube container or a 13.6 m trailer, by space and by weight.
containerFit in TypeScript
logistics.delivery-date
Estimated dispatch and delivery dates from order time, dispatch cut-off, service days, weekends and UK bank holidays.
deliveryDate in TypeScript
logistics.route-distance
Total great-circle distance of an ordered list of stops, leg by leg, optionally back to the start, to the millimetre.
routeDistance in TypeScript
manufacturing.bom-explode
Explode a multi-level bill of materials into exact total quantities per component, with scrap and cycle checks.
explodeBom in TypeScript
manufacturing.variance
Standard costing variances: material price and usage, labour rate and efficiency, favourable or adverse.
costVariances in TypeScript
money.convert
Convert an amount to another currency at a supplied exact rate, with an explicit rounding mode.
convertMoney in TypeScript
monitor.mttr
MTTR, MTBF, downtime and incident counts for a reporting window, from a list of incidents.
reliabilityStats in TypeScript
net.ip-classify
Classify an IPv4 or IPv6 address as loopback, private, link-local, multicast, documentation, CGNAT or global.
classifyIp in TypeScript
retail.loyalty-points
Loyalty points for a purchase: redeem in blocks, earn on what is paid, with tier multipliers.
loyaltyPoints in TypeScript
retail.promotion-apply
Apply BOGOF, 3-for-2, percent off, amount off and multibuy deals to a basket, best for the customer, allocated to lines.
applyPromotions in TypeScript
subscriptions.usage-tiered
Price metered usage against tiers, graduated or volume, with an optional flat fee per tier.
priceUsage in TypeScript
telecoms.call-rating
Rate a call from a rate deck: longest-prefix destination match, billing increments, connection fee and minimum charge.
rateCall in TypeScript
todo.item
The to-do item type (Todo, TodoDraft, Recurrence) and its validators, with a message per field.
A group of 2:
validateDraft, validateTodo
todo.parse-date-phrase
Read a typed due date like "tomorrow", "next friday", "in 2 weeks" or "2026-10-01" as a date, relative to today.
parseDatePhrase in TypeScript
todo.parse-repeat
Read a Repeat box, "every 2 weeks" or "every monday on 2026-10-05", as a todo's recurrence, or null.
parseRepeat in TypeScript
todo.sort
Sort todos by manual order, due date, priority, creation time or title, stably, with sensible tie-breakers.
sortTodos in TypeScript
validation.iban
Check an IBAN against the ISO 13616 mod-97-10 checksum and the registered length for its country.
isIban in TypeScript
validation.uk-vat-number
Check a UK VAT registration number against HMRC's mod-97 checksum, including the post-2010 9755 variant.
isUkVatNumber in TypeScript
auth.login-throttle
Allow a login attempt or lock the account out, from its recent failed attempts, with the seconds until it may retry.
loginThrottle in TypeScript
banking.fees-cap
Apply a monthly fee cap to a list of account charges: charge up to the cap, waive the rest.
applyFeeCap in TypeScriptLevel 3 business operation
finance.invoice.calculate
Calculate a complete invoice: line nets, VAT per line, totals and a VAT summary grouped by rate.
calculateInvoice in TypeScript
charity.reclaim-batch
Gift Aid claim totals for a period from donation records: donor lines, aggregated small gifts, tax due.
giftAidClaimBatch in TypeScript
auth.validate-password-change
Check a change-password form: current password given and correct, new one meeting the policy and different.
validatePasswordChange in TypeScript
auth.validate-registration
Validate a sign-up form (email, password, name) in one call, with a message per field, in the browser and the API alike.
validateRegistration in TypeScript
charts.bar-chart
Complete bar chart geometry as data, grouped or stacked: plot area, axes, gridlines, bar rectangles, colours, legend.
barChart in TypeScript
charts.line-chart
Complete line chart geometry as data: plot area, number or date axes, gridlines, series paths, colours, legend.
lineChart in TypeScript
finance.credit-note.calculate
Credit note against an original invoice, by units or by amount, with VAT at the original tax point's rates.
calculateCreditNote in TypeScript
retail.basket-total
Total a basket: line prices, promotions, a basket discount, VAT per line and delivery, into one checked total.
basketTotal in TypeScript
subscriptions.invoice
A subscription renewal invoice: plan, add-ons and usage, coupon discounts by billing period, and VAT.
renewalInvoice in TypeScript
auth.validate-login
Check a login form (email, password): the normalised email to look up, or a message for each field to fix.
validateLogin in TypeScript