{
    "openapi": "3.1.0",
    "info": {
        "title": "NolaPro API v2",
        "version": "2.0.0",
        "description": "JSON API for NolaPro ERP. Every write goes through NolaPro's own models, so the API enforces the same accounting rules the application does."
    },
    "servers": [
        {
            "url": "https://{site}.nolapro.com/!/api/v2",
            "description": "Hosted site"
        },
        {
            "url": "https://{host}/{np}/!/api/v2",
            "description": "Self-hosted install"
        }
    ],
    "tags": [
        {
            "name": "inventorytransfers",
            "x-title": "Stock transfers",
            "x-schema": "RefInventorytransfers",
            "x-table": "invcotransfer",
            "x-humankey": "",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "x-scopegroup": "items",
            "x-handbuilt": true,
            "x-delta": false,
            "description": "Stock moving between companies or locations. Hand-built: the record has no single owning company - it carries `gencompanyidfrom` and `gencompanyidto` - so the generic engine would treat it as install-wide and show every company's transfers to everyone."
        },
        {
            "name": "inventorycounts",
            "x-title": "Stock counts",
            "x-schema": "RefInventorycounts",
            "x-table": "invcountbatch",
            "x-humankey": "",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "x-scopegroup": "items",
            "x-delta": true,
            "description": "Physical and cycle count batches, and the lines being counted."
        },
        {
            "name": "customfields",
            "x-title": "Custom fields",
            "x-schema": "CustomFieldDefinition",
            "x-table": "flexfield",
            "x-humankey": "",
            "x-group": "Start",
            "x-feature": [],
            "x-status": "live",
            "x-handbuilt": true,
            "x-delta": false,
            "description": "Custom field definitions - what the flexible fields on this install are called, what they accept, and which resource each belongs to. Hand-built: the engine must not serve `flexfield` generically, because a generic read would return the definitions this endpoint deliberately hides."
        },
        {
            "name": "me",
            "x-title": "Token info",
            "x-schema": "Me",
            "x-table": "genapitoken",
            "x-humankey": "",
            "x-group": "Start",
            "x-feature": [],
            "x-status": "live",
            "description": "What the token you are holding is, and what it can do. The first call to make when something returns 403 and you do not know why.",
            "x-singleton": true,
            "x-delta": false
        },
        {
            "name": "customers",
            "x-title": "Customers",
            "x-status": "live",
            "x-schema": "Customer",
            "x-table": "customer",
            "x-humankey": "customercode",
            "x-scopegroup": "customers",
            "x-group": "Income",
            "x-feature": [],
            "description": "The companies you invoice. A customer carries terms, credit limit, tax group, and any number of ship-to addresses.",
            "x-notes": [
                "Customers are never removed. `DELETE /customers/{id}` sets the cancel flag and keeps history intact."
            ],
            "x-delta": true,
            "x-unique-humankey": true
        },
        {
            "name": "shiptos",
            "x-title": "Ship-tos",
            "x-schema": "RefShiptos",
            "x-table": "shipto",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Delivery addresses on a customer. An order or invoice ships to one of these.",
            "x-scopegroup": "customers",
            "x-delta": true
        },
        {
            "name": "contactnames",
            "x-title": "Contacts",
            "x-schema": "RefContactnames",
            "x-table": "contactname",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Named contacts on a customer or ship-to.",
            "x-scopegroup": "customers",
            "x-delta": false
        },
        {
            "name": "b2busers",
            "x-title": "B2B users",
            "x-schema": "RefB2busers",
            "x-table": "b2buser",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Customer-portal logins. Credentials are never returned.",
            "x-scopegroup": "customers",
            "x-delta": true
        },
        {
            "name": "orders",
            "x-title": "Orders",
            "x-schema": "RefOrders",
            "x-table": "arorder",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Sales orders. **One table serves several documents.** `ordertype` is `fulfillment`, `service` or `rental`; `status` is `quote`, `unconfirmed`, `open`, `partial` or `billed`. A **quote is `status: \"quote\"`** - it is not an order type, and it wins over `ordertype`, so a service order that is still a quote is a quote. Converting a quote to an order is a `PATCH` of `status` to `open`, which commits inventory.",
            "x-scopegroup": "orders",
            "x-children": [
                "lines",
                "hours",
                "shipments"
            ],
            "x-delta": true
        },
        {
            "name": "orderlines",
            "x-title": "Order lines",
            "x-schema": "RefOrderlines",
            "x-table": "arorderdetail",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Lines on an order. Normally sent nested inside the order. `arorderdetail` has no `cancel` column, so `DELETE` removes the row and renumbers its siblings rather than cancelling it.",
            "x-scopegroup": "orders",
            "x-delta": true
        },
        {
            "name": "shipments",
            "x-title": "Shipments",
            "x-schema": "RefShipments",
            "x-table": "arordership",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "A shipment against an order. Can be sent nested in `POST /orders` or created on its own afterwards; both go through the same code path. A quote cannot ship.",
            "x-scopegroup": "shipments",
            "x-children": [
                "lines"
            ],
            "x-delta": true
        },
        {
            "name": "shipmentlines",
            "x-title": "Shipment lines",
            "x-schema": "RefShipmentlines",
            "x-table": "arordershipdetail",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "What was shipped, per line.",
            "x-scopegroup": "shipments",
            "x-delta": true
        },
        {
            "name": "invoices",
            "x-title": "Invoices",
            "x-schema": "RefInvoices",
            "x-table": "arinvoice",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "AR invoices. Lines go in the same request - see Conventions on nested writes.",
            "x-scopegroup": "invoices",
            "x-delta": true,
            "x-humankey": "invoicenumber"
        },
        {
            "name": "invoicelines",
            "x-title": "Invoice lines",
            "x-schema": "RefInvoicelines",
            "x-table": "arinvoicedetail",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Lines on an invoice. Normally sent nested inside the invoice rather than created here.",
            "x-scopegroup": "invoices",
            "x-delta": true
        },
        {
            "name": "payments",
            "x-title": "Payments",
            "x-schema": "RefPayments",
            "x-table": "arinvoicepaymentdetail",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Payments applied to an invoice.",
            "x-scopegroup": "payments",
            "x-delta": false
        },
        {
            "name": "orderdeposits",
            "x-title": "Order deposits",
            "x-schema": "RefOrderdeposits",
            "x-table": "arorder_deposit",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Deposits taken against an order. **A deposit alone makes an order invoiceable** - `arorder2invoice.php` admits an order that has a deposit even when nothing has shipped. Card brand and number are never returned.",
            "x-scopegroup": "payments",
            "x-delta": true
        },
        {
            "name": "ardailycloses",
            "x-title": "Daily closes",
            "x-schema": "RefArdailycloses",
            "x-table": "ardailyclose",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "End-of-day close records.",
            "x-scopegroup": "payments",
            "x-delta": false
        },
        {
            "name": "rmareturns",
            "x-title": "RMA returns",
            "x-schema": "RefRmareturns",
            "x-table": "rma_arorder_returned",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Returned lines against an RMA.",
            "x-scopegroup": "orders",
            "x-delta": false
        },
        {
            "name": "serviceordertimes",
            "x-title": "Service order time",
            "x-schema": "RefServiceordertimes",
            "x-table": "arserviceorder_time",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Hours logged against a service order (an `order` with `ordertype` `service`). Hours are not order lines: they become lines only when billed, at which point `status` becomes `billed` and the record is frozen.",
            "x-scopegroup": "orders",
            "x-delta": true
        },
        {
            "name": "jobs",
            "x-title": "Jobs",
            "x-schema": "RefJobs",
            "x-table": "job",
            "x-group": "Income",
            "x-feature": [
                "construction"
            ],
            "x-status": "live",
            "description": "Construction jobs. Costs and revenue can be tracked against one.",
            "x-scopegroup": "jobs",
            "x-delta": true
        },
        {
            "name": "draws",
            "x-title": "Draws",
            "x-schema": "RefDraws",
            "x-table": "draw",
            "x-group": "Income",
            "x-feature": [
                "construction"
            ],
            "x-status": "live",
            "description": "Construction draws against a job.",
            "x-scopegroup": "jobs",
            "x-delta": false
        },
        {
            "name": "checkaccounts",
            "x-title": "Bank accounts",
            "x-schema": "RefCheckaccounts",
            "x-table": "checkacct",
            "x-humankey": "name",
            "x-scopegroup": "banking",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only.** Bank accounts carry `accountnumber`, positive-pay SFTP credentials and private keys. Those are never returned, and the account is not writable through the API - changing where money moves is not an integration operation.",
            "x-delta": false
        },
        {
            "name": "bankdeposits",
            "x-title": "Bank deposits",
            "x-schema": "RefBankdeposits",
            "x-table": "bankdeposit",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "Deposits into a bank account.",
            "x-scopegroup": "banking",
            "x-delta": false
        },
        {
            "name": "ccaccounts",
            "x-title": "Credit card accounts",
            "x-schema": "RefCcaccounts",
            "x-table": "ccaccount",
            "x-humankey": "name",
            "x-scopegroup": "banking",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "Merchant accounts used to take card payments. The processor behind each one is a static lookup and is not exposed.",
            "x-delta": true
        },
        {
            "name": "ccprocessors",
            "x-title": "Card processors",
            "x-schema": "RefCcprocessors",
            "x-table": "ccprocessor",
            "x-humankey": "name",
            "x-scopegroup": "banking",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "Payment processors NolaPro can talk to. **A static table** - `dbupdate.php` rebuilds it on every update, so it is read-only and your own rows would not survive. Referenced by `ccaccounts.ccprocessorid`.",
            "x-delta": false
        },
        {
            "name": "ccterminals",
            "x-title": "Card terminals",
            "x-schema": "RefCcterminals",
            "x-table": "ccterminal",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "Physical card terminals.",
            "x-scopegroup": "banking",
            "x-delta": false
        },
        {
            "name": "ccterminallogs",
            "x-title": "Card terminal logs",
            "x-schema": "RefCcterminallogs",
            "x-table": "ccterminallog",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only.** Terminal activity log.",
            "x-scopegroup": "banking",
            "x-delta": false
        },
        {
            "name": "cctransactions",
            "x-title": "Card transactions",
            "x-schema": "RefCctransactions",
            "x-table": "cctransaction",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only.** Gateway transaction records. Card data is never returned.",
            "x-scopegroup": "banking",
            "x-delta": false
        },
        {
            "name": "ccpurchases",
            "x-title": "Card purchases",
            "x-schema": "RefCcpurchases",
            "x-table": "ccpurchase",
            "x-group": "Banking",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only.** Card purchase records.",
            "x-scopegroup": "banking",
            "x-delta": false
        },
        {
            "name": "vendors",
            "x-title": "Vendors",
            "x-schema": "RefVendors",
            "x-table": "vendor",
            "x-humankey": "vendorcode",
            "x-scopegroup": "vendors",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "The companies you buy from. Bank details are never returned - see Conventions.",
            "x-delta": true
        },
        {
            "name": "vendortypes",
            "x-title": "Vendor types",
            "x-schema": "RefVendortypes",
            "x-table": "vendortype",
            "x-humankey": "description",
            "x-scopegroup": "vendors",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Vendor classification.",
            "x-delta": false
        },
        {
            "name": "vendororderfroms",
            "x-title": "Vendor order-from addresses",
            "x-schema": "RefVendororderfroms",
            "x-table": "vendor_orderfrom",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Alternate addresses a vendor is ordered from.",
            "x-scopegroup": "vendors",
            "x-delta": false
        },
        {
            "name": "purchaseorders",
            "x-title": "Purchase orders",
            "x-schema": "RefPurchaseorders",
            "x-table": "invpo",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Purchase orders to a vendor. A **proposal is `status: \"proposal\"`**, the same shape as an AR quote. `ponumber` is assigned under a lock when omitted.",
            "x-scopegroup": "purchaseorders",
            "x-children": [
                "lines"
            ],
            "x-delta": true
        },
        {
            "name": "purchaseorderlines",
            "x-title": "PO lines",
            "x-schema": "RefPurchaseorderlines",
            "x-table": "invpodetail",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Lines on a purchase order. Normally sent nested inside the PO.",
            "x-scopegroup": "purchaseorders",
            "x-delta": false
        },
        {
            "name": "invreceives",
            "x-title": "PO receipts",
            "x-schema": "RefInvreceives",
            "x-table": "invreceive",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "What was received against a purchase order.",
            "x-scopegroup": "purchaseorders",
            "x-delta": true
        },
        {
            "name": "apbills",
            "x-title": "AP bills",
            "x-schema": "RefApbills",
            "x-table": "apbill",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Vendor bills. Lines go in the same request - see Conventions on nested writes.",
            "x-scopegroup": "bills",
            "x-delta": true
        },
        {
            "name": "apbilllines",
            "x-title": "AP bill lines",
            "x-schema": "RefApbilllines",
            "x-table": "apbilldetail",
            "x-group": "Expenses",
            "x-feature": [],
            "x-status": "live",
            "description": "Lines on a vendor bill. Normally sent nested inside the bill.",
            "x-scopegroup": "bills",
            "x-delta": false
        },
        {
            "name": "items",
            "x-title": "Items",
            "x-status": "live",
            "x-schema": "Item",
            "x-table": "item",
            "x-humankey": "itemcode",
            "x-scopegroup": "items",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "description": "Inventory and non-inventory items. Stock levels are per location and are never written directly, only moved.",
            "x-notes": [
                "You cannot set `onhand`. Quantity changes come from receipts, shipments, and adjustments so that cost layers and the inventory GL account stay in step."
            ],
            "x-delta": true
        },
        {
            "name": "itemvendors",
            "x-title": "Item vendors",
            "x-schema": "RefItemvendors",
            "x-table": "itemvendor",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Which vendors supply an item, and at what cost.",
            "x-scopegroup": "items",
            "x-delta": true
        },
        {
            "name": "itemoptions",
            "x-title": "Item options",
            "x-schema": "RefItemoptions",
            "x-table": "itemoption",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Options on a configurable item.",
            "x-scopegroup": "items",
            "x-delta": true
        },
        {
            "name": "itemoptiongroups",
            "x-title": "Item option groups",
            "x-schema": "RefItemoptiongroups",
            "x-table": "itemoptiongroup",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Groups that item options belong to.",
            "x-scopegroup": "items",
            "x-delta": true
        },
        {
            "name": "itemcomparisongroups",
            "x-title": "Item comparison groups",
            "x-schema": "RefItemcomparisongroups",
            "x-table": "itemcomparisongroup",
            "x-humankey": "name",
            "x-scopegroup": "items",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Groups used to compare items against each other in the storefront.",
            "x-delta": false
        },
        {
            "name": "itempricespecials",
            "x-title": "Item price specials",
            "x-schema": "RefItempricespecials",
            "x-table": "itempricespecial",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Special pricing headers. The rows live in `itempricespecialdetails`.",
            "x-scopegroup": "items",
            "x-delta": false
        },
        {
            "name": "itempricespecialdetails",
            "x-title": "Item price special rows",
            "x-schema": "RefItempricespecialdetails",
            "x-table": "itempricespecialdetail",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Special pricing rows for an item.",
            "x-scopegroup": "items",
            "x-delta": false
        },
        {
            "name": "inventorylocations",
            "x-title": "Inventory locations",
            "x-schema": "RefInventorylocations",
            "x-table": "inventorylocation",
            "x-humankey": "locationcode",
            "x-scopegroup": "items",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Warehouses and stocking locations. Address-shaped rather than code-shaped. **Carries both `cancel` and `inactive`**, which mean different things - a location can be active but temporarily not stocking. Read-only in this release; creating one has physical inventory consequences.",
            "x-delta": true
        },
        {
            "name": "unitnames",
            "x-title": "Unit names",
            "x-schema": "Unitname",
            "x-table": "unitname",
            "x-humankey": "unitname",
            "x-scopegroup": "items",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Units of measure - Each, M, Pound - used on items, invoice lines and order lines. This list is **not** company scoped. `unitname` has no company column, so every company on the install shares one set of units and a change here is visible to all of them immediately.",
            "x-delta": true,
            "x-unique-humankey": true,
            "x-reactivate-warning": "unit_reactivated"
        },
        {
            "name": "pricelevels",
            "x-title": "Price levels",
            "x-schema": "RefPricelevels",
            "x-table": "pricelevel",
            "x-group": "Inventory",
            "x-feature": [
                "inventory"
            ],
            "x-status": "live",
            "description": "Customer price tiers.",
            "x-scopegroup": "items",
            "x-delta": true
        },
        {
            "name": "igroups",
            "x-title": "Customer groups",
            "x-schema": "RefIgroups",
            "x-table": "igroup",
            "x-humankey": "groupcode",
            "x-scopegroup": "setup",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "description": "Customer groups, the target of `customer.groupid`. Not to be confused with `customergroup`, which is a customer-to-group join table and is not exposed.",
            "x-delta": true
        },
        {
            "name": "areas",
            "x-title": "Areas",
            "x-schema": "RefAreas",
            "x-table": "area",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "description": "Geographic or sales areas. Empty on many installs.",
            "x-delta": false
        },
        {
            "name": "assets",
            "x-title": "Assets",
            "x-schema": "RefAssets",
            "x-table": "asset",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "description": "Fixed assets.",
            "x-scopegroup": "assets",
            "x-delta": false
        },
        {
            "name": "assetcategories",
            "x-title": "Asset categories",
            "x-schema": "RefAssetcategories",
            "x-table": "assetcategory",
            "x-group": "Inventory",
            "x-feature": [],
            "x-status": "live",
            "description": "Grouping for fixed assets.",
            "x-scopegroup": "assets",
            "x-delta": false
        },
        {
            "name": "itemidentifiers",
            "x-title": "Item identifier types",
            "x-schema": "RefItemidentifiers",
            "x-table": "itemidentifier",
            "x-group": "Inventory",
            "x-feature": [
                "inventory",
                "serialnuminnotes"
            ],
            "x-status": "live",
            "description": "What this company tracks per item: serial number, lot, expiry. `datatype` is the value shape; `singleton` means one unit per value, which is how a serial number differs from a lot.",
            "x-scopegroup": "items",
            "x-delta": false
        },
        {
            "name": "itemidentifierdetails",
            "x-title": "Item identifier values",
            "x-schema": "RefItemidentifierdetails",
            "x-table": "itemidentifierdetail",
            "x-group": "Inventory",
            "x-feature": [
                "inventory",
                "serialnuminnotes"
            ],
            "x-status": "live",
            "description": "The actual serials and lots in stock, per item and location. `quantityonhand` and `quantityavailable` are generated columns and are never writable.",
            "x-scopegroup": "items",
            "x-delta": false
        },
        {
            "name": "itemidentifiertransactions",
            "x-title": "Identifier movements",
            "x-schema": "RefItemidentifiertransactions",
            "x-table": "itemidentifiertransaction",
            "x-group": "Inventory",
            "x-feature": [
                "inventory",
                "serialnuminnotes"
            ],
            "x-status": "live",
            "description": "**Read-only.** Which serials and lots moved on which shipment or receipt. Written by the transaction that moved them, never directly - a movement with no transaction behind it would be a stock record nothing can explain.",
            "x-scopegroup": "items",
            "x-delta": false
        },
        {
            "name": "glaccounts",
            "x-title": "GL accounts",
            "x-schema": "RefGlaccounts",
            "x-table": "glaccount",
            "x-humankey": "name",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "**`name` holds the account number and `description` holds the label.** That is backwards from most expectations and it is the single most important thing to know about this resource. Scoped per company, on the `companyid` column.",
            "x-delta": true
        },
        {
            "name": "glaccounttypes",
            "x-title": "GL account types",
            "x-schema": "RefGlaccounttypes",
            "x-table": "accounttype",
            "x-humankey": "description",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "The account types behind `glaccounts.accounttypeid` - asset, liability, income and so on. Fixed by double-entry accounting rather than by configuration, so read-only.",
            "x-delta": false
        },
        {
            "name": "glcategories",
            "x-title": "GL categories",
            "x-schema": "RefGlcategories",
            "x-table": "glcategory",
            "x-humankey": "code",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "Categories used to group GL activity for reporting.",
            "x-delta": false
        },
        {
            "name": "glcategorytypes",
            "x-title": "GL category types",
            "x-schema": "RefGlcategorytypes",
            "x-table": "glcategorytype",
            "x-humankey": "description",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "Types used to classify GL categories. Referenced by `glcategories.glcategorytypeid`.",
            "x-delta": false
        },
        {
            "name": "glcostcenters",
            "x-title": "Cost centers",
            "x-schema": "RefGlcostcenters",
            "x-table": "gl_costcenter",
            "x-humankey": "description",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "GL cost centers. Note the table has only a description, no separate code.",
            "x-delta": false
        },
        {
            "name": "gltransactions",
            "x-title": "GL transactions",
            "x-status": "live",
            "x-schema": "GlTransaction",
            "x-table": "gltransvoucher",
            "x-humankey": "voucher",
            "x-scopegroup": "gltransactions",
            "x-group": "Ledger",
            "x-feature": [],
            "description": "Direct journal entries. The most powerful endpoint here, and the one with the strictest rules.",
            "x-notes": [
                "A transaction set must balance: the signed amounts must sum to exactly zero. An unbalanced set is rejected with `422 gl_set_unbalanced` and nothing is written.",
                "A set needs at least two lines. A one-line journal entry is not a journal entry."
            ],
            "x-delta": true
        },
        {
            "name": "costcodes",
            "x-title": "Cost codes",
            "x-schema": "RefCostcodes",
            "x-table": "costcode",
            "x-humankey": "code",
            "x-scopegroup": "glaccounts",
            "x-group": "Ledger",
            "x-feature": [],
            "x-status": "live",
            "description": "Cost codes for job and project costing.",
            "x-delta": false
        },
        {
            "name": "taxclasses",
            "x-title": "Tax classes",
            "x-schema": "RefTaxclasses",
            "x-table": "taxclass",
            "x-humankey": "name",
            "x-scopegroup": "tax",
            "x-group": "Tax",
            "x-feature": [
                "taxclasses"
            ],
            "x-status": "live",
            "description": "Tax classes applied to items. The `avatax*` columns mirror an AvaTax tax code and are only meaningful on installs using it.",
            "x-delta": false
        },
        {
            "name": "taxexempts",
            "x-title": "Tax exemptions",
            "x-schema": "RefTaxexempts",
            "x-table": "taxexempt",
            "x-humankey": "exemptname",
            "x-scopegroup": "tax",
            "x-group": "Tax",
            "x-feature": [],
            "x-status": "live",
            "description": "Tax exemption reasons and their rates. More than a label - each carries a `state` and a `taxrate`.",
            "x-delta": true
        },
        {
            "name": "taxgroups",
            "x-title": "Tax groups",
            "x-schema": "RefTaxgroups",
            "x-table": "taxgroup",
            "x-humankey": "groupcode",
            "x-scopegroup": "tax",
            "x-group": "Tax",
            "x-feature": [],
            "x-status": "live",
            "description": "Tax groups. Empty on many installs until tax is configured.",
            "x-delta": true
        },
        {
            "name": "taxableentityusecodes",
            "x-title": "Entity use codes",
            "x-schema": "RefTaxableentityusecodes",
            "x-table": "taxableentityusecode",
            "x-humankey": "code",
            "x-scopegroup": "tax",
            "x-group": "Tax",
            "x-feature": [
                "taxclasses"
            ],
            "x-status": "live",
            "description": "Taxable entity use codes, used by tax engines to classify why a sale is exempt.",
            "x-delta": false
        },
        {
            "name": "producttypetaxes",
            "x-title": "Product tax types",
            "x-schema": "RefProducttypetaxes",
            "x-table": "producttypetax",
            "x-group": "Tax",
            "x-feature": [],
            "x-status": "live",
            "description": "Product tax classification.",
            "x-scopegroup": "tax",
            "x-delta": false
        },
        {
            "name": "departments",
            "x-title": "Departments",
            "x-schema": "RefDepartments",
            "x-table": "department",
            "x-humankey": "code",
            "x-scopegroup": "payroll",
            "x-group": "Payroll",
            "x-feature": [
                "payroll"
            ],
            "x-status": "live",
            "description": "Departments, used for payroll expense allocation. Each carries the GL accounts wages and taxes post to.",
            "x-delta": false
        },
        {
            "name": "premployees",
            "x-title": "Employees",
            "x-schema": "RefPremployees",
            "x-table": "premployee",
            "x-humankey": "",
            "x-scopegroup": "payroll",
            "x-group": "Payroll",
            "x-feature": [
                "payroll"
            ],
            "x-status": "live",
            "description": "**Read-only and minimal, for the same reason as users, only more so.** The stored row carries social security numbers, pay rates, bank details and tax withholding. None of that is returned and none of it is writable. This resource exists only so `salesman.payrollid` can be resolved to a name.",
            "x-delta": true
        },
        {
            "name": "prpaytypes",
            "x-title": "Pay types",
            "x-schema": "RefPrpaytypes",
            "x-table": "prpaytype",
            "x-group": "Payroll",
            "x-feature": [
                "payroll"
            ],
            "x-status": "live",
            "description": "Payroll pay types.",
            "x-scopegroup": "payroll",
            "x-delta": false
        },
        {
            "name": "teamprojects",
            "x-title": "Projects",
            "x-schema": "RefTeamprojects",
            "x-table": "teamproject",
            "x-humankey": "projectcode",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Projects. `projectcode` is the display id (TPM-001).",
            "x-delta": true
        },
        {
            "name": "teamprojecttasks",
            "x-title": "Tasks",
            "x-schema": "RefTeamprojecttasks",
            "x-table": "teamprojecttask",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Tasks. `parenttaskid` nests one level only; `taskseq` is the per-project number.",
            "x-delta": true
        },
        {
            "name": "teamprojectmilestones",
            "x-title": "Milestones",
            "x-schema": "RefTeamprojectmilestones",
            "x-table": "teamprojectmilestone",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Milestones within a project.",
            "x-delta": true
        },
        {
            "name": "teamprojectstatuses",
            "x-title": "Task statuses",
            "x-schema": "RefTeamprojectstatuses",
            "x-table": "teamprojectstatus",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Custom task statuses. `iscomplete` marks the ones that close a task.",
            "x-delta": true
        },
        {
            "name": "teamprojectcategories",
            "x-title": "Project categories",
            "x-schema": "RefTeamprojectcategories",
            "x-table": "teamprojectcategory",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Optional grouping for projects.",
            "x-delta": true
        },
        {
            "name": "teamprojecttags",
            "x-title": "Project tags",
            "x-schema": "RefTeamprojecttags",
            "x-table": "teamprojecttag",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Tags, shared company-wide across all projects.",
            "x-delta": true
        },
        {
            "name": "teamprojecttaglinks",
            "x-title": "Project tag links",
            "x-schema": "RefTeamprojecttaglinks",
            "x-table": "teamprojecttaglink",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Links a tag to a project.",
            "x-delta": true
        },
        {
            "name": "teamprojecttasktags",
            "x-title": "Task tag links",
            "x-schema": "RefTeamprojecttasktags",
            "x-table": "teamprojecttasktag",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Links a tag to a task.",
            "x-delta": true
        },
        {
            "name": "teamprojectcomments",
            "x-title": "Task comments",
            "x-schema": "RefTeamprojectcomments",
            "x-table": "teamprojecttaskcomment",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Discussion on a task.",
            "x-delta": true
        },
        {
            "name": "teamprojectchecklists",
            "x-title": "Task checklists",
            "x-schema": "RefTeamprojectchecklists",
            "x-table": "teamprojecttaskchecklist",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Checklist sub-items on a task.",
            "x-delta": true
        },
        {
            "name": "teamprojecttimelogs",
            "x-title": "Time logs",
            "x-schema": "RefTeamprojecttimelogs",
            "x-table": "teamprojecttimelog",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Time entries. `teamprojecttaskid` 0 means project-level. `status` 1 is a running timer.",
            "x-delta": true
        },
        {
            "name": "teamprojectmembers",
            "x-title": "Project members",
            "x-schema": "RefTeamprojectmembers",
            "x-table": "teamprojectuser",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Team membership. `role` 0=Manager, 1=Member, 2=Viewer.",
            "x-delta": true
        },
        {
            "name": "teamprojecttaskassignees",
            "x-title": "Task assignees",
            "x-schema": "RefTeamprojecttaskassignees",
            "x-table": "teamprojecttaskuser",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Who a task is assigned to. Many-to-many.",
            "x-delta": true
        },
        {
            "name": "teamprojecttaskwatchers",
            "x-title": "Task watchers",
            "x-schema": "RefTeamprojecttaskwatchers",
            "x-table": "teamprojecttaskwatcher",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Who gets notified about a task.",
            "x-delta": true
        },
        {
            "name": "teamprojecttaskdependencies",
            "x-title": "Task dependencies",
            "x-schema": "RefTeamprojecttaskdependencies",
            "x-table": "teamprojecttaskdependency",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Finish-to-start links. Advisory only - nothing is blocked from starting.",
            "x-delta": true
        },
        {
            "name": "teamprojectreminders",
            "x-title": "Reminders",
            "x-schema": "RefTeamprojectreminders",
            "x-table": "teamprojectreminder",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Scheduled reminders on a task.",
            "x-delta": true
        },
        {
            "name": "teamprojectrecurringtasks",
            "x-title": "Recurring tasks",
            "x-schema": "RefTeamprojectrecurringtasks",
            "x-table": "teamprojecttaskrecurring",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Recurring task definitions, generated by the processqueue cron.",
            "x-delta": true
        },
        {
            "name": "teamprojectautomations",
            "x-title": "Automations",
            "x-schema": "RefTeamprojectautomations",
            "x-table": "teamprojectautomation",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Rules that act on project events.",
            "x-delta": true
        },
        {
            "name": "teamprojecttemplates",
            "x-title": "Project templates",
            "x-schema": "RefTeamprojecttemplates",
            "x-table": "teamprojecttemplate",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Saved project templates.",
            "x-delta": true
        },
        {
            "name": "teamprojecttemplateitems",
            "x-title": "Template items",
            "x-schema": "RefTeamprojecttemplateitems",
            "x-table": "teamprojecttemplateitem",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Milestones and tasks inside a template.",
            "x-delta": true
        },
        {
            "name": "teamprojectviews",
            "x-title": "Saved views",
            "x-schema": "RefTeamprojectviews",
            "x-table": "teamprojectview",
            "x-humankey": "name",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Saved board and list views.",
            "x-delta": true
        },
        {
            "name": "teamprojectsettings",
            "x-title": "Project settings",
            "x-schema": "RefTeamprojectsettings",
            "x-table": "teamprojectsetting",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "Module settings, key/value.",
            "x-delta": true
        },
        {
            "name": "teamprojectactivity",
            "x-title": "Task activity",
            "x-schema": "RefTeamprojectactivity",
            "x-table": "teamprojecttaskactivity",
            "x-humankey": "",
            "x-scopegroup": "projects",
            "x-group": "Projects",
            "x-feature": [
                "teamproject"
            ],
            "x-status": "live",
            "description": "**Read-only.** Auto-logged change history. Written by the application, never by a caller.",
            "x-delta": false
        },
        {
            "name": "buildings",
            "x-title": "Buildings",
            "x-schema": "RefBuildings",
            "x-table": "building",
            "x-group": "Property Management",
            "x-feature": [],
            "x-status": "live",
            "description": "Buildings that rentable units belong to.",
            "x-scopegroup": "properties",
            "x-delta": false
        },
        {
            "name": "buildingtypes",
            "x-title": "Building types",
            "x-schema": "RefBuildingtypes",
            "x-table": "buildingtype",
            "x-group": "Property Management",
            "x-feature": [],
            "x-status": "live",
            "description": "Classification for buildings.",
            "x-scopegroup": "properties",
            "x-delta": false
        },
        {
            "name": "leases",
            "x-title": "Leases",
            "x-schema": "RefLeases",
            "x-table": "lease",
            "x-group": "Property Management",
            "x-feature": [],
            "x-status": "live",
            "description": "Lease agreements.",
            "x-scopegroup": "properties",
            "x-delta": false
        },
        {
            "name": "units",
            "x-title": "Units",
            "x-schema": "RefUnits",
            "x-table": "unit",
            "x-group": "Property Management",
            "x-feature": [],
            "x-status": "live",
            "description": "Rentable units in a building.",
            "x-scopegroup": "properties",
            "x-delta": false
        },
        {
            "name": "sites",
            "x-title": "Sites",
            "x-schema": "RefSites",
            "x-table": "site",
            "x-group": "Property Management",
            "x-feature": [
                "construction"
            ],
            "x-status": "live",
            "description": "Physical sites a job runs at.",
            "x-scopegroup": "jobs",
            "x-delta": false
        },
        {
            "name": "estquotes",
            "x-title": "Estimating quotes",
            "x-schema": "RefEstquotes",
            "x-table": "estquotequote",
            "x-group": "NolaPrint",
            "x-feature": [],
            "x-status": "live",
            "description": "Quotes from the Estimating module. A **different thing** from an AR quote, which is an `order` with `status` `quote` - see the `orders` resource. `ordertype` 2 is a rental order, not a quote.",
            "x-scopegroup": "estimating",
            "x-delta": true,
            "x-feature-any": [
                "Printshop_pricelist",
                "Printshop_std"
            ]
        },
        {
            "name": "estquotepricelists",
            "x-title": "Quote price lists",
            "x-schema": "RefEstquotepricelists",
            "x-table": "estquotepricelist",
            "x-group": "NolaPrint",
            "x-feature": [],
            "x-status": "live",
            "description": "Price lists used by Estimating quotes. The wider Estimating configuration surface (about 40 tables) is a module pass of its own and is not exposed here.",
            "x-scopegroup": "estimating",
            "x-delta": true,
            "x-feature-any": [
                "Printshop_pricelist",
                "Printshop_std"
            ]
        },
        {
            "name": "quotecomments",
            "x-title": "Quote comments",
            "x-schema": "RefQuotecomments",
            "x-table": "quotecomment",
            "x-humankey": "comments",
            "x-scopegroup": "setup",
            "x-group": "NolaPrint",
            "x-feature": [],
            "x-status": "live",
            "description": "Standard comment blocks attached to customers for quoting. **This is `quotecomment`, not `estquotequotenotes`** - the UI joins `quotecomment.id = customer.quotecommentid` (`arcustcsvlist.php:118`). The Estimating table of a similar name is a different thing and is not exposed.",
            "x-delta": true
        },
        {
            "name": "genusers",
            "x-title": "Users",
            "x-schema": "RefGenusers",
            "x-table": "genuser",
            "x-humankey": "name",
            "x-scopegroup": "users",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only, and deliberately minimal.** Users are who NolaPro attributes work to, so an integrator needs to resolve an id to a name - and nothing more. Credentials, API keys, two-factor secrets and the ninety-odd preference columns are never returned.",
            "x-delta": false
        },
        {
            "name": "extusers",
            "x-title": "External users",
            "x-schema": "RefExtusers",
            "x-table": "extuser",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only and minimal.** External identities. Credentials are never returned.",
            "x-scopegroup": "users",
            "x-delta": true
        },
        {
            "name": "emailtemplates",
            "x-title": "Email templates",
            "x-schema": "RefEmailtemplates",
            "x-table": "emailtemplate",
            "x-humankey": "action",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Templates behind the emails NolaPro sends. `action` is the key that identifies which email a template is for; `name` is the human label. **No `lastchangedate`**, so no `modifiedsince`.",
            "x-delta": false
        },
        {
            "name": "webhooks",
            "x-title": "Webhook subscriptions",
            "x-schema": "RefWebhooks",
            "x-table": "genapiwebhook",
            "x-group": "Admin",
            "x-scopegroup": "setup",
            "x-feature": [],
            "x-humankey": "description",
            "x-status": "live",
            "description": "Subscriptions that push events to your server instead of you polling for them. A subscription belongs to the token that created it and only ever delivers events that token has the scope to read. **The envelope, signature verification and the retry schedule are in [Webhooks](../webhooks.html)** - read that first; this page is the subscription object and the event catalogue.",
            "x-delta": false
        },
        {
            "name": "requestlog",
            "x-title": "Request log",
            "x-schema": "RequestLogEntry",
            "x-table": "genapilog",
            "x-group": "Admin",
            "x-scopegroup": "setup",
            "x-feature": [],
            "x-humankey": "route",
            "x-status": "live",
            "description": "What this token has been doing. Useful when a call failed hours ago and nobody kept the response.",
            "x-delta": ""
        },
        {
            "name": "surveys",
            "x-title": "Surveys",
            "x-schema": "RefSurveys",
            "x-table": "survey",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [
                "survey"
            ],
            "x-status": "live",
            "description": "Customer surveys, referenced from email templates and areas.",
            "x-delta": false
        },
        {
            "name": "taskstatuses",
            "x-title": "CRM task statuses",
            "x-schema": "RefTaskstatuses",
            "x-table": "taskstatus",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Task statuses used by CRM activity. **This table has no `lastchangedate`**, so `modifiedsince` is not offered here.",
            "x-delta": false
        },
        {
            "name": "stages",
            "x-title": "Stages",
            "x-schema": "RefStages",
            "x-table": "stage",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Pipeline stages.",
            "x-scopegroup": "setup",
            "x-delta": false
        },
        {
            "name": "stagetypes",
            "x-title": "Stage types",
            "x-schema": "RefStagetypes",
            "x-table": "stagetype",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "**Read-only.** A static table rebuilt on every NolaPro update.",
            "x-scopegroup": "setup",
            "x-delta": false
        },
        {
            "name": "invoiceterms",
            "x-title": "Invoice terms",
            "x-schema": "RefInvoiceterms",
            "x-table": "invoiceterms",
            "x-humankey": "verbal",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Payment terms. **The most referenced lookup in the API** - 18,112 of 18,115 customers point at one. Shared install-wide, so a change here is visible to every company.",
            "x-delta": true
        },
        {
            "name": "salesmen",
            "x-title": "Salespeople",
            "x-schema": "RefSalesmen",
            "x-table": "salesman",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Salespeople and service reps. One table serves both roles - `salesman` and `servicerep` are flags, so filter on those rather than expecting two resources.",
            "x-delta": true
        },
        {
            "name": "salescategories",
            "x-title": "Sales categories",
            "x-schema": "RefSalescategories",
            "x-table": "sales_categories",
            "x-humankey": "description",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Sales categories, used to group revenue. Note this table tracks modification in `lastupdatedate`, not `lastchangedate`, so `modifiedsince` reads that column here.",
            "x-delta": false
        },
        {
            "name": "discounts",
            "x-title": "Discounts",
            "x-schema": "RefDiscounts",
            "x-table": "discount",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Discount definitions.",
            "x-scopegroup": "setup",
            "x-delta": false
        },
        {
            "name": "coupons",
            "x-title": "Coupons",
            "x-schema": "RefCoupons",
            "x-table": "coupons",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Coupon codes.",
            "x-scopegroup": "setup",
            "x-delta": false
        },
        {
            "name": "carriers",
            "x-title": "Carriers",
            "x-schema": "RefCarriers",
            "x-table": "carrier",
            "x-humankey": "description",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Shipping carriers.",
            "x-delta": false
        },
        {
            "name": "carrierservices",
            "x-title": "Carrier services",
            "x-schema": "RefCarrierservices",
            "x-table": "carrierservice",
            "x-humankey": "description",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Service levels offered by a carrier.",
            "x-delta": false
        },
        {
            "name": "interestchargeoptions",
            "x-title": "Interest charge options",
            "x-schema": "RefInterestchargeoptions",
            "x-table": "interestchargeoption",
            "x-humankey": "",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "**This table has no name, code or label** - it is an id and a rate. There is therefore no code sibling anywhere that references it, permanently. Read-only.",
            "x-delta": false
        },
        {
            "name": "worktypes",
            "x-title": "Work types",
            "x-schema": "RefWorktypes",
            "x-table": "worktype",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Work types used on projects, tasks and time logs.",
            "x-delta": false
        },
        {
            "name": "worksubtypes",
            "x-title": "Work subtypes",
            "x-schema": "RefWorksubtypes",
            "x-table": "worksubtype",
            "x-group": "Admin",
            "x-feature": [],
            "x-status": "live",
            "description": "Subtypes under a work type.",
            "x-scopegroup": "setup",
            "x-delta": false
        },
        {
            "name": "serviceworktypes",
            "x-title": "Service work types",
            "x-schema": "RefServiceworktypes",
            "x-table": "service_worktype",
            "x-humankey": "name",
            "x-scopegroup": "setup",
            "x-group": "Admin",
            "x-feature": [
                "servicePF"
            ],
            "x-status": "live",
            "description": "Work types for Service Orders. Only populated on installs running that module.",
            "x-delta": true
        },
        {
            "name": "countries",
            "x-title": "Countries",
            "x-schema": "RefCountries",
            "x-table": "countries",
            "x-humankey": "countries_iso_code_2",
            "x-scopegroup": "reference",
            "x-group": "Reference data",
            "x-feature": [],
            "x-status": "live",
            "description": "Countries, with the number formatting NolaPro uses for each. The formatting columns are worth reading if you display amounts - they explain why a total renders differently per country.",
            "x-delta": false
        },
        {
            "name": "zones",
            "x-title": "Zones",
            "x-schema": "RefZones",
            "x-table": "zones",
            "x-humankey": "zone_code",
            "x-scopegroup": "reference",
            "x-group": "Reference data",
            "x-feature": [],
            "x-status": "live",
            "description": "States and provinces. Static reference data - no writes, no cancel flag, no external ids. Its identifier is `zone_id`, because that is what the column is called.",
            "x-delta": false
        },
        {
            "name": "timezones",
            "x-title": "Time zones",
            "x-schema": "RefTimezones",
            "x-table": "timezone",
            "x-humankey": "name",
            "x-scopegroup": "reference",
            "x-group": "Reference data",
            "x-feature": [],
            "x-status": "live",
            "description": "IANA time zone names. Static reference data.",
            "x-delta": false
        },
        {
            "name": "mobilecarriers",
            "x-title": "Mobile carriers",
            "x-schema": "RefMobilecarriers",
            "x-table": "mobilecarriers",
            "x-humankey": "carriername",
            "x-scopegroup": "reference",
            "x-group": "Reference data",
            "x-feature": [],
            "x-status": "live",
            "description": "Mobile carriers and their SMS gateway domains, used for text notifications.",
            "x-delta": false
        },
        {
            "name": "orderstatusoptions",
            "x-title": "Service order statuses",
            "x-schema": "RefOrderstatusoptions",
            "x-table": "arstatusoptions",
            "x-group": "Income",
            "x-feature": [],
            "x-status": "live",
            "description": "Custom service order statuses (\"In Progress\", \"Waiting for Parts\", \"Order Complete\"...). Referenced by `statusid` on a service order; `complete` marks the statuses that mean the work is done.",
            "x-humankey": "description",
            "x-delta": true,
            "x-scopegroup": "orders"
        }
    ],
    "paths": {
        "/customers": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "List customers.",
                "description": "Filters are a fixed allow-list. Anything not listed here returns 400 naming the parameter.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "companyname",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Company name. Partial match, case-insensitive."
                    },
                    {
                        "name": "customercode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Customer code. Partial match."
                    },
                    {
                        "name": "city",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Billing city. Partial match."
                    },
                    {
                        "name": "state",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Billing state. Partial match."
                    },
                    {
                        "name": "zip",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Billing postal code. Partial match."
                    },
                    {
                        "name": "salesmanid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one salesperson."
                    },
                    {
                        "name": "groupid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customer group."
                    },
                    {
                        "name": "closed",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "`true` or `false`. **Omitted means both** - closed customers still appear, because closed is a status, not a cancellation (D23)."
                    },
                    {
                        "name": "on_hold",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "`true` or `false`. Omitted means both. On hold blocks new orders; it does not hide the customer."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`, which hides cancelled records. Pass `true` for only cancelled, or `any` for both."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "1-based. Defaults to 1."
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Defaults to 50, capped at 250."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Look up by your own key instead of by `id`. Unique per company and per system tag."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of customers.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/CustomerList"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "An unknown filter parameter was sent.",
                        "x-code": "unknown_parameter"
                    },
                    "401": {
                        "description": "Missing, malformed, revoked, or expired token.",
                        "x-code": "unauthorized"
                    },
                    "403": {
                        "description": "The token lacks `customers:read`, or the user has no rights to customers.",
                        "x-code": "forbidden"
                    }
                }
            },
            "post": {
                "tags": [
                    "customers"
                ],
                "summary": "Create a customer.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/CustomerCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Created.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Customer"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A field is missing or the wrong type.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "A customer with this name already exists in the company.",
                        "x-code": "duplicate"
                    },
                    "422": {
                        "description": "The values are well-formed but break an accounting rule, for example an unknown terms code.",
                        "x-code": "rule_violation"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/customers/{id}": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "Retrieve one customer.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The customer.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Customer"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No customer with that id in this company.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "customers"
                ],
                "summary": "Update a customer.",
                "description": "Only the fields you send are changed. There is no PUT - with 168 fields a full replace would blank everything you omitted.",
                "x-scope": "customers:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/CustomerCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated customer.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Customer"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No customer with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "If-Match did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "customers"
                ],
                "summary": "Cancel one customer.",
                "description": "Sets the cancel flag through the same path the application uses, so whatever bookkeeping cancelling this record implies happens with it. Nothing is removed. Cancelling an already cancelled customer succeeds.",
                "x-scope": "customers:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled customer.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Customer"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "The token has customers:write but not customers:cancel.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No customer with that id in this company.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "Cannot be cancelled in its current state. The message says why.",
                        "x-code": "cannot_cancel"
                    }
                }
            }
        },
        "/customers/{id}/balance": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "Open balance, per currency.",
                "description": "Replaces v1's customer-balance action. Computed by `Customer_model::getAgingSummary()` - the AR Aging report's own code, so this and the report cannot disagree.\n\nFor the same figure split by age, use [`/customers/{id}/aging`](#get-customers-id-aging).",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    },
                    {
                        "name": "asofdate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "format": "date"
                        },
                        "description": "Defaults to today."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Balances by currency.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCustomerBalance"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No customer with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/gltransactions/{id}/lines": {
            "get": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "The lines of one journal voucher.",
                "description": "Every debit and credit the voucher wrote.\n\n`/gltransactions` publishes the voucher header - who wrote it, when, what it totals. This is what it actually did to the ledger, which is what reconciliation and trial-balance work needs. Amounts are signed and the lines of one voucher sum to zero.\n\nThe rows carry no company of their own; they are scoped through the voucher, so a voucher in another company answers 404 rather than an empty page.",
                "x-scope": "gltransactions:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The voucher id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows, oldest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/GlTransactionLine"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company. The same answer whether it does not exist or belongs to someone else, so a caller cannot probe another company's ids.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/items/{id}/transactions": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Stock movement history for an item.",
                "description": "Every movement that made the item's stock what it is: receipts, shipments, adjustments, transfers and commitments.\n\n`/items/{id}/stock` answers what is on hand right now. This answers how it got there, which is what you need when your own system and NolaPro disagree about a number.\n\n`trtype` 1 is a commitment against an open order and is deliberately excluded from on-hand - filter it out to see physical movement only. Cancelled rows stay readable and do not count toward stock.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The item id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows, oldest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/ItemTransaction"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company. The same answer whether it does not exist or belongs to someone else, so a caller cannot probe another company's ids.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/apbills/{id}/payments": {
            "get": {
                "tags": [
                    "apbills"
                ],
                "summary": "Payments applied to a vendor bill.",
                "description": "What paid this bill, when, and through which voucher.\n\nA customer payment against an invoice is a first-class resource (`/payments`). Its counterpart on the payables side lives here, against the bill it settles. Anyone reconciling accounts payable needs it to close the loop between a bill and the money that left.\n\nA voided cheque keeps its row and carries `checkvoid` with a reversing voucher, rather than disappearing.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The bill id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows, oldest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/ApbillPayment"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company. The same answer whether it does not exist or belongs to someone else, so a caller cannot probe another company's ids.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/glaccounts/{id}/periods": {
            "get": {
                "tags": [
                    "glaccounts"
                ],
                "summary": "Period totals for one GL account.",
                "description": "The per-period balances NolaPro maintains for the account - the series a trial balance or a comparative statement is built from.\n\n`/glaccounts/{id}/balance` answers for a single date. This answers for every period, split into posted, unposted, and the year-end entries that close the books.\n\n**Do not recompute these by summing `gltransaction`.** NolaPro maintains them through period close, so a recomputed figure will disagree with the books after any adjustment or closing entry - and the books are the version the accountant already signed.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The GL account id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows, oldest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/GlAccountPeriod"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company. The same answer whether it does not exist or belongs to someone else, so a caller cannot probe another company's ids.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/shipments/{id}/packages": {
            "get": {
                "tags": [
                    "shipments"
                ],
                "summary": "Packages in a shipment, with their tracking numbers.",
                "description": "Parcel-level detail: what went in which box, what it weighed, what the carrier charged, and the tracking number.\n\nThis is where tracking numbers live. The order-level audit trail records that a shipment happened; the number a customer types into a carrier's site is here, per package - which matters because one shipment is often several boxes with several numbers.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The shipment id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/ShipmentPackage"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/bankdeposits/{id}/lines": {
            "get": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "What went into a deposit.",
                "description": "The composition of a bank deposit - each payment or item that made up the total.\n\nReconciling a deposit against a bank statement needs the parts, not the sum: the statement shows one credit, and matching it means knowing which receipts were banked together.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The deposit id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/BankDepositLine"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/invoices/{id}/notes": {
            "get": {
                "tags": [
                    "invoices"
                ],
                "summary": "Notes on an invoice.",
                "description": "Operational context that lives with the document - why a price was changed, what a customer asked for, what to tell the driver.\n\n`hide` keeps a note off the printed invoice. A note with `linenumber` set belongs to that line rather than the document as a whole.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The invoice id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/DocumentNote"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/orders/{id}/notes": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Notes on an order and its lines.",
                "description": "As with invoices, but for orders. `private` marks a note as internal - a support or CRM integration reading these should respect it before showing anything to a customer.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The order id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/DocumentNote"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/invoicelines/{id}/tax": {
            "get": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "Tax charged on one invoice line, by jurisdiction.",
                "description": "Documents report a tax total. This is the breakdown - which tax authority charged what, at which rate, and how much of the line was exempt.\n\nAnyone filing returns from NolaPro data, or reconciling against an external tax service, needs the per-jurisdiction detail rather than the sum.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The invoice line id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/LineTaxDetail"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/orders/{id}/tax": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Tax charged on an order, by jurisdiction.",
                "description": "The order-level equivalent of the invoice line breakdown. Useful before the order is billed, when the invoice tax detail does not exist yet.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The order id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/OrderTax"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/items/{id}/locations": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Stock and reorder settings per location.",
                "description": "`/items/{id}/stock` answers for one location at a time. This lists every location the item is stocked at, with on-hand, bin, cost layers and the seasonal minimum, maximum and reorder quantities.\n\nA customer running more than one warehouse needs this to route fulfilment, and to avoid promising stock that is in the wrong building.\n\nOnly locations that exist are listed. NolaPro keeps stock rows against internal pseudo-locations with negative ids and no matching location record; those are omitted, because an id you cannot fetch, adjust or ship from is not a warehouse.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The item id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of rows.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/ItemLocationStock"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such parent record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/customfields": {
            "get": {
                "tags": [
                    "customfields"
                ],
                "summary": "The custom fields configured on this install.",
                "description": "What custom fields exist, what type each is, whether it is required, and - for a select - the values it accepts.\n\nValues alone are not usable: receiving `{\"warranty_code\": \"AX-9\"}` tells you nothing about whether that field is required or what it accepts, and you would find out by having a write rejected. Read this first.\n\n**`key` is the name to use, and it is given rather than derived.** Most fields carry an internal name; a few do not, and those get a stable `custom_<id>` instead. Do not build the key yourself.\n\nFields NolaPro marks as hidden are excluded - the screens do not show them and neither does this.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "resource",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one resource, e.g. `customers`. An unknown name is refused rather than answered with an empty page."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of definitions.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/CustomFieldDefinition"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "The `resource` named does not exist.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/items/{id}/barcode": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "The item code as a scannable barcode image.",
                "description": "Returns `image/png`. Encodes the item's own code unless you pass `value`.\n\n**Code 39 cannot encode every item code.** Its alphabet is digits, A-Z, space and `-.$/+%`; an underscore or a lower-case letter produces an image that looks like a barcode and will not scan, which a warehouse discovers at the shelf. Those are refused with the offending characters named - use `code128b` for arbitrary text.\n\nThe label SHEET (many labels, a stored template, print-ready) is a different thing and is not this endpoint.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The item id."
                    },
                    {
                        "name": "symbology",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "enum": [
                                "code39",
                                "code128a",
                                "code128b",
                                "i25"
                            ]
                        },
                        "description": "Defaults to code39."
                    },
                    {
                        "name": "value",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Encode this instead of the item code."
                    },
                    {
                        "name": "width",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Pixels, 40-2000. Defaults to 460."
                    },
                    {
                        "name": "height",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Pixels, 20-1000. Defaults to 120."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A PNG image.",
                        "content": {
                            "image/png": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A parameter was malformed.",
                        "x-codes": {
                            "invalid_enum": "`symbology` is not one of the four supported.",
                            "invalid_type": "`width` or `height` was not a whole number."
                        }
                    },
                    "422": {
                        "description": "The value cannot be encoded.",
                        "x-codes": {
                            "rule_violation": "The symbology cannot represent those characters, or the item has no code.",
                            "unknown_value": "No such item in this company."
                        }
                    }
                }
            }
        },
        "/items/{id}/adjustments": {
            "post": {
                "tags": [
                    "items"
                ],
                "summary": "Correct the stock level for an item at a location.",
                "description": "The only way to move stock that is not a side effect of shipping or receiving a document.\n\nSend **either** `quantity` (a signed change) **or** `onhand` (the level it should end at). They are the same operation - the delta is `onhand - current` - and letting you send the target means NolaPro computes the difference at the moment it applies it, rather than you computing it against a figure that may already have moved.\n\nThis posts to the general ledger. The adjustment raises an `INVADJ` voucher against the item's inventory GL account, so the response carries `voucherid` and the period rules apply.",
                "x-action": true,
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The item id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "locationid"
                                ],
                                "properties": {
                                    "locationid": {
                                        "type": "integer",
                                        "description": "Where the stock is held.",
                                        "x-idonly": true
                                    },
                                    "quantity": {
                                        "type": "string",
                                        "x-qty": true,
                                        "x-example": "-3.000000",
                                        "description": "Signed change. Negative writes stock off."
                                    },
                                    "onhand": {
                                        "type": "string",
                                        "x-qty": true,
                                        "x-example": "40.000000",
                                        "description": "The level it should end at. NolaPro works out the difference."
                                    },
                                    "description": {
                                        "type": "string",
                                        "maxLength": 255,
                                        "description": "Why. Appears on the movement and the voucher."
                                    },
                                    "date": {
                                        "type": "string",
                                        "format": "date",
                                        "description": "Posting date. Defaults to today."
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Adjusted. Carries the new level and the voucher it posted.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "itemid": {
                                            "type": "integer"
                                        },
                                        "locationid": {
                                            "type": "integer"
                                        },
                                        "quantity": {
                                            "type": "string",
                                            "x-qty": true,
                                            "description": "The change actually applied."
                                        },
                                        "onhandwas": {
                                            "type": "string",
                                            "x-qty": true,
                                            "description": "The level before."
                                        },
                                        "onhand": {
                                            "type": "string",
                                            "x-qty": true,
                                            "description": "The level now, read back from stock."
                                        },
                                        "date": {
                                            "type": "string",
                                            "format": "date"
                                        },
                                        "voucherid": {
                                            "type": "integer",
                                            "x-idonly": true,
                                            "description": "The INVADJ voucher. Pair with GET /gltransactions/{id}/lines."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-codes": {
                            "invalid_request": "Neither or both of `quantity` and `onhand` were sent, or `locationid` is missing.",
                            "invalid_type": "A quantity was not a decimal string.",
                            "invalid_precision": "More than six decimal places."
                        }
                    },
                    "422": {
                        "description": "The adjustment was refused. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "It would change nothing, or the item is not stock-tracked there.",
                            "period_closed": "The GL period is closed, so the voucher has nowhere to post.",
                            "unknown_value": "No such item or location in this company."
                        }
                    }
                }
            }
        },
        "/inventorycounts": {
            "get": {
                "tags": [
                    "inventorycounts"
                ],
                "summary": "Stock count batches.",
                "description": "Physical and cycle count batches - how stock stays honest.\n\nA batch is opened against a location, assigned to someone, counted line by line, and then POSTED, which turns each variance into a stock adjustment through the batch's adjustment type. The read endpoints here expose the batch and its lines; posting is not yet available through the API.\n\n`countset` on a line is the field to watch: it separates a counted zero from a line nobody has looked at, and a `count` of 0 means nothing without it.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "type",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one type: `cycle` or `physical`."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one stocking location."
                    },
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to the user the batch is assigned to."
                    },
                    {
                        "name": "posted",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Whether the batch has been posted to stock. `true` or `false`."
                    },
                    {
                        "name": "complete",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Whether counting has finished. A complete batch is not necessarily posted."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInventorycounts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/inventorycounts/{id}": {
            "get": {
                "tags": [
                    "inventorycounts"
                ],
                "summary": "One count batch.",
                "description": "The batch header. Its lines are at `/inventorycounts/{id}/lines`.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInventorycounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No such record in this company.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/inventorycounts/{id}/lines": {
            "get": {
                "tags": [
                    "inventorycounts"
                ],
                "summary": "What is being counted, and what was found.",
                "description": "One line per item in the batch. `count` is what was found and `countset` says whether anyone has looked yet - a zero count and an uncounted line are different facts and the API keeps them apart.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The batch id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of lines.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/InventoryCountLine"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/inventorytransfers": {
            "get": {
                "tags": [
                    "inventorytransfers"
                ],
                "summary": "Inter-company and inter-location stock transfers.",
                "description": "Stock moving between companies or locations.\n\nA transfer is raised, assigned, picked, shipped and received, and `status` says where it is. The line records both what was sent and what was ordered, so a short send is visible - shrinkage lives in the gap between the two.\n\n**These records span two companies by design.** A transfer is visible to the sender and the receiver, and to nobody else: `gencompanyidfrom` or `gencompanyidto` must be yours.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status: `newunassigned`, `assigned`, `accepted`, `picked`, `shipped` or `receivedcompleted`."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInventorytransfers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/inventorytransfers/{id}": {
            "get": {
                "tags": [
                    "inventorytransfers"
                ],
                "summary": "One transfer.",
                "description": "The transfer header. Its lines are at `/inventorytransfers/{id}/lines`.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInventorytransfers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No such record in this company.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/inventorytransfers/{id}/lines": {
            "get": {
                "tags": [
                    "inventorytransfers"
                ],
                "summary": "What is moving, and what has arrived.",
                "description": "`quantity` is what was sent and `quantityordered` what was asked for; `received` says whether it has landed. Comparing them is how a short receipt is found, and a transfer system that cannot record one cannot account for shrinkage.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The transfer id."
                    },
                    {
                        "$ref": "#/components/parameters/Page"
                    },
                    {
                        "$ref": "#/components/parameters/PerPage"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "A page of lines.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/InventoryTransferLine"
                                            }
                                        },
                                        "page": {
                                            "type": "integer"
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "No such record in this company.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/items/{id}/stock": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Retrieve stock for an item at one location.",
                "description": "Replaces the legacy `item/get_item_stats` and `item/get_item_cost` endpoints.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The item id."
                    },
                    {
                        "name": "location",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Inventory location id. Required: stock is meaningless without it."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Stock and cost at that location.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ItemStock"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Unknown item, or the item is not stocked at that location.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/invoices": {
            "get": {
                "tags": [
                    "invoices"
                ],
                "summary": "List invoices.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "orderbycompanyid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderbycompanyid."
                    },
                    {
                        "name": "shiptocompanyid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one shiptocompanyid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "salesmanid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one salesmanid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "orderid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderid."
                    },
                    {
                        "name": "ponumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "ponumber. Partial match, case-insensitive."
                    },
                    {
                        "name": "invoicenumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInvoices"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "invoices"
                ],
                "summary": "Create.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoiceCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The invoice was written and POSTED.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/InvoiceCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "shipto_mismatch": "The `shiptoid` belongs to a different customer.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/gltransactions": {
            "post": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "Post a journal entry.",
                "description": "Writes and **posts** a balanced journal entry in one transaction.\n\nThis is the strictest endpoint in the API, and deliberately so - an unbalanced or half-written set makes the trial balance wrong and keeps it wrong. Every rule below is checked before anything is written:\n\n| Rule | Refusal |\n|---|---|\n| The signed amounts sum to exactly zero | `422 gl_set_unbalanced`, with the difference |\n| At least two lines | `400 invalid_request` |\n| Every account exists in your company | `422 unknown_value`, naming the line |\n| The period is open | `422 period_closed` |\n| Amounts are decimal strings | `400 invalid_type` |\n\n`Idempotency-Key` matters more here than anywhere else: a retry after a lost response must not post the entry twice.",
                "x-scope": "gltransactions:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/GlTransactionCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Posted.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/GlTransactionCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "Malformed: no date, a float amount, lines missing entirely.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "conflicting_reference": "An id and its name sibling were both sent and disagree.",
                            "gl_set_too_short": "Fewer than two lines. A one-sided entry is not a journal entry.",
                            "gl_set_unbalanced": "The signed amounts do not sum to zero.",
                            "period_closed": "The GL period containing the date is closed.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            },
            "get": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "Journal entries.",
                "description": "Vouchers in this company, newest id first. The lines are on [`/glaccounts/{id}/activity`](glaccounts.html#get-glaccounts-id-activity).",
                "x-scope": "gltransactions:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`, which hides cancelled records. Pass `true` for only cancelled, or `any` for both."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Look up by your own key instead of by `id`. Unique per company and per system tag."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Vouchers.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/GlTransaction"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/unitnames": {
            "get": {
                "tags": [
                    "unitnames"
                ],
                "summary": "List units of measure.",
                "description": "Small and stable - most installs have fewer than fifty. This list is **not** company scoped. `unitname` has no company column, so every company on the install shares one set of units and a change here is visible to all of them immediately.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "unitname",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`, which hides cancelled records. Pass `true` for only cancelled, or `any` for both."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The units.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/Unitname"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `unitnames:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "unitnames"
                ],
                "summary": "Create a unit of measure.",
                "description": "If a **cancelled** unit already has this name it is reactivated rather than duplicated, and `_meta.warnings` says so. If an **active** one does, you get `409`. Matching is case insensitive. This list is **not** company scoped. `unitname` has no company column, so every company on the install shares one set of units and a change here is visible to all of them immediately.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "unitname"
                                ],
                                "properties": {
                                    "unitname": {
                                        "type": "string",
                                        "maxLength": 50,
                                        "description": "Trimmed. Must not be empty.",
                                        "x-example": "Pallet"
                                    },
                                    "externalid": {
                                        "type": "string",
                                        "description": "Optional. Your own key, scoped to your company."
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The unit. Check `_meta.warnings` for `unit_reactivated`.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Unitname"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "`name` was missing, empty, or whitespace only.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "An active unit already has that name. The body names its id.",
                        "x-code": "duplicate"
                    },
                    "403": {
                        "description": "Token lacks `unitnames:write`.",
                        "x-code": "insufficient_scope"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/unitnames/{id}": {
            "get": {
                "tags": [
                    "unitnames"
                ],
                "summary": "Retrieve one unit.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The unit id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The unit.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Unitname"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No unit with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "unitnames"
                ],
                "summary": "Rename a unit.",
                "description": "The only writable field is `name`. **This renames the unit for every company on the install**, including on documents already issued, so `_meta.warnings` always carries `shared_across_companies`. Send `If-Match` if anything else might be editing it.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The unit id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "unitname": {
                                        "type": "string",
                                        "maxLength": 50,
                                        "x-example": "Pallet"
                                    },
                                    "externalid": {
                                        "type": "string"
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated unit.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Unitname"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "`name` was empty or too long.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No unit with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "Another active unit already has that name.",
                        "x-code": "duplicate"
                    }
                }
            },
            "delete": {
                "tags": [
                    "unitnames"
                ],
                "summary": "Cancel a unit.",
                "description": "Sets the cancel flag. Nothing is removed, and documents that already reference this unit keep doing so - `_meta.warnings` reports how many. Needs `unitnames:cancel`, which `unitnames:write` does not imply. Cancelling an already cancelled unit succeeds. This list is **not** company scoped. `unitname` has no company column, so every company on the install shares one set of units and a change here is visible to all of them immediately.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The unit id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled unit. Check `_meta.warnings` for `unit_in_use`.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Unitname"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token has `unitnames:write` but not `unitnames:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No unit with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/unitnames/batch": {
            "post": {
                "tags": [
                    "unitnames"
                ],
                "summary": "Create many units in one request.",
                "description": "Always answers `207`, with one entry per item in the order sent. See [Conventions](../conventions.html#one-record-per-post).",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "type": "object",
                                    "required": [
                                        "unitname"
                                    ],
                                    "properties": {
                                        "unitname": {
                                            "type": "string",
                                            "maxLength": 50
                                        }
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results. Individual failures are reported inside `results`, never by the status code."
                    },
                    "400": {
                        "description": "The envelope was wrong - not an array, or over the size cap.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/salesmen/batch": {
            "post": {
                "tags": [
                    "salesmen"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefSalesmen"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/salesmen": {
            "get": {
                "tags": [
                    "salesmen"
                ],
                "summary": "List salespeople.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefSalesmen"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `salesmen:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "salesmen"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSalesmen"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalesmen"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/salesmen/{id}": {
            "get": {
                "tags": [
                    "salesmen"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalesmen"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "salesmen"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSalesmen"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalesmen"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "salesmen"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalesmen"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `salesmen:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/salescategories/batch": {
            "post": {
                "tags": [
                    "salescategories"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefSalescategories"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/salescategories": {
            "get": {
                "tags": [
                    "salescategories"
                ],
                "summary": "List sales categories.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefSalescategories"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `salescategories:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "salescategories"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSalescategories"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalescategories"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/salescategories/{id}": {
            "get": {
                "tags": [
                    "salescategories"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalescategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "salescategories"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSalescategories"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalescategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "salescategories"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSalescategories"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `salescategories:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/taxgroups/batch": {
            "post": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTaxgroups"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxgroups": {
            "get": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "List tax groups.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "groupcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTaxgroups"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `taxgroups:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "Create.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxgroups"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxgroups"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxgroups/{id}": {
            "get": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxgroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "Update.",
                "x-scope": "tax:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxgroups"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxgroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "taxgroups"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "tax:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxgroups"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `taxgroups:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/igroups/batch": {
            "post": {
                "tags": [
                    "igroups"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefIgroups"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/igroups": {
            "get": {
                "tags": [
                    "igroups"
                ],
                "summary": "List customer groups.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "groupcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefIgroups"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `igroups:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "igroups"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefIgroups"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefIgroups"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/igroups/{id}": {
            "get": {
                "tags": [
                    "igroups"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefIgroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "igroups"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefIgroups"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefIgroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "igroups"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefIgroups"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `igroups:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/taskstatuses/batch": {
            "post": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTaskstatuses"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taskstatuses": {
            "get": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "List task statuses.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTaskstatuses"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `taskstatuses:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaskstatuses"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaskstatuses"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taskstatuses/{id}": {
            "get": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaskstatuses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaskstatuses"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaskstatuses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "taskstatuses"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaskstatuses"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `taskstatuses:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/emailtemplates/batch": {
            "post": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefEmailtemplates"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/emailtemplates": {
            "get": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "List email templates.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "action",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefEmailtemplates"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `emailtemplates:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEmailtemplates"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEmailtemplates"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/emailtemplates/{id}": {
            "get": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEmailtemplates"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEmailtemplates"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEmailtemplates"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "emailtemplates"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEmailtemplates"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `emailtemplates:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/serviceworktypes/batch": {
            "post": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefServiceworktypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/serviceworktypes": {
            "get": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "List service work types.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefServiceworktypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `serviceworktypes:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefServiceworktypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceworktypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/serviceworktypes/{id}": {
            "get": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceworktypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefServiceworktypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceworktypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "serviceworktypes"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceworktypes"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `serviceworktypes:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/taxableentityusecodes/batch": {
            "post": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxableentityusecodes": {
            "get": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "List entity use codes.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `taxableentityusecodes:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "Create.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxableentityusecodes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxableentityusecodes/{id}": {
            "get": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "Update.",
                "x-scope": "tax:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxableentityusecodes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "taxableentityusecodes"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "tax:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxableentityusecodes"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `taxableentityusecodes:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/invoiceterms/batch": {
            "post": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefInvoiceterms"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invoiceterms": {
            "get": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "List invoice terms.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "verbal",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInvoiceterms"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `invoiceterms:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefInvoiceterms"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoiceterms"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invoiceterms/{id}": {
            "get": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoiceterms"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefInvoiceterms"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoiceterms"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "invoiceterms"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoiceterms"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `invoiceterms:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/taxexempts/batch": {
            "post": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTaxexempts"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxexempts": {
            "get": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "List tax exemptions.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "exemptname",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTaxexempts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `taxexempts:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "Create.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxexempts"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxexempts"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxexempts/{id}": {
            "get": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxexempts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "Update.",
                "x-scope": "tax:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxexempts"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxexempts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "taxexempts"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "tax:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxexempts"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `taxexempts:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/areas/batch": {
            "post": {
                "tags": [
                    "areas"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefAreas"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/areas": {
            "get": {
                "tags": [
                    "areas"
                ],
                "summary": "List areas.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefAreas"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `areas:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "areas"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAreas"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAreas"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or invalid.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/areas/{id}": {
            "get": {
                "tags": [
                    "areas"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAreas"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "areas"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAreas"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAreas"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "areas"
                ],
                "summary": "Cancel.",
                "description": "Sets the cancel flag. Nothing is removed.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAreas"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `areas:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/zones": {
            "get": {
                "tags": [
                    "zones"
                ],
                "summary": "List zones.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefZones"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `zones:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/zones/{id}": {
            "get": {
                "tags": [
                    "zones"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefZones"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/countries": {
            "get": {
                "tags": [
                    "countries"
                ],
                "summary": "List countries.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCountries"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `countries:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/countries/{id}": {
            "get": {
                "tags": [
                    "countries"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCountries"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/timezones": {
            "get": {
                "tags": [
                    "timezones"
                ],
                "summary": "List time zones.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTimezones"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `timezones:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/timezones/{id}": {
            "get": {
                "tags": [
                    "timezones"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTimezones"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/mobilecarriers": {
            "get": {
                "tags": [
                    "mobilecarriers"
                ],
                "summary": "List mobile carriers.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefMobilecarriers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `mobilecarriers:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/mobilecarriers/{id}": {
            "get": {
                "tags": [
                    "mobilecarriers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "reference:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefMobilecarriers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glaccounts": {
            "get": {
                "tags": [
                    "glaccounts"
                ],
                "summary": "List gl accounts.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGlaccounts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `glaccounts:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/glaccounts/{id}": {
            "get": {
                "tags": [
                    "glaccounts"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlaccounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/inventorylocations": {
            "get": {
                "tags": [
                    "inventorylocations"
                ],
                "summary": "List inventory locations.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "locationcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInventorylocations"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `inventorylocations:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/inventorylocations/{id}": {
            "get": {
                "tags": [
                    "inventorylocations"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInventorylocations"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/interestchargeoptions": {
            "get": {
                "tags": [
                    "interestchargeoptions"
                ],
                "summary": "List interest charge options.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInterestchargeoptions"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `interestchargeoptions:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/interestchargeoptions/{id}": {
            "get": {
                "tags": [
                    "interestchargeoptions"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInterestchargeoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/genusers": {
            "get": {
                "tags": [
                    "genusers"
                ],
                "summary": "List users.",
                "x-scope": "users:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGenusers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `genusers:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/genusers/{id}": {
            "get": {
                "tags": [
                    "genusers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "users:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGenusers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/premployees": {
            "get": {
                "tags": [
                    "premployees"
                ],
                "summary": "List employees.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPremployees"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `premployees:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/premployees/{id}": {
            "get": {
                "tags": [
                    "premployees"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPremployees"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/checkaccounts": {
            "get": {
                "tags": [
                    "checkaccounts"
                ],
                "summary": "List bank accounts.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCheckaccounts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `checkaccounts:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/checkaccounts/{id}": {
            "get": {
                "tags": [
                    "checkaccounts"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCheckaccounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ccaccounts/batch": {
            "post": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "Create many.",
                "x-scope": "banking:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCcaccounts"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ccaccounts": {
            "get": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "List credit card accounts.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCcaccounts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `ccaccounts:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "Create.",
                "x-scope": "banking:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCcaccounts"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcaccounts"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ccaccounts/{id}": {
            "get": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcaccounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "Update.",
                "x-scope": "banking:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCcaccounts"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcaccounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "ccaccounts"
                ],
                "summary": "Cancel.",
                "x-scope": "banking:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcaccounts"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `ccaccounts:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/costcodes/batch": {
            "post": {
                "tags": [
                    "costcodes"
                ],
                "summary": "Create many.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCostcodes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/costcodes": {
            "get": {
                "tags": [
                    "costcodes"
                ],
                "summary": "List cost codes.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCostcodes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `costcodes:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "costcodes"
                ],
                "summary": "Create.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCostcodes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCostcodes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/costcodes/{id}": {
            "get": {
                "tags": [
                    "costcodes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCostcodes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "costcodes"
                ],
                "summary": "Update.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCostcodes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCostcodes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "costcodes"
                ],
                "summary": "Cancel.",
                "x-scope": "glaccounts:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCostcodes"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `costcodes:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glcategories/batch": {
            "post": {
                "tags": [
                    "glcategories"
                ],
                "summary": "Create many.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefGlcategories"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcategories": {
            "get": {
                "tags": [
                    "glcategories"
                ],
                "summary": "List gl categories.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGlcategories"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `glcategories:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "glcategories"
                ],
                "summary": "Create.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategories"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcategories/{id}": {
            "get": {
                "tags": [
                    "glcategories"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "glcategories"
                ],
                "summary": "Update.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "glcategories"
                ],
                "summary": "Cancel.",
                "x-scope": "glaccounts:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategories"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `glcategories:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glcostcenters/batch": {
            "post": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "Create many.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefGlcostcenters"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcostcenters": {
            "get": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "List cost centers.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGlcostcenters"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `glcostcenters:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "Create.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcostcenters"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcostcenters"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcostcenters/{id}": {
            "get": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcostcenters"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "Update.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcostcenters"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcostcenters"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "glcostcenters"
                ],
                "summary": "Cancel.",
                "x-scope": "glaccounts:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcostcenters"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `glcostcenters:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/departments/batch": {
            "post": {
                "tags": [
                    "departments"
                ],
                "summary": "Create many.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefDepartments"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/departments": {
            "get": {
                "tags": [
                    "departments"
                ],
                "summary": "List departments.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefDepartments"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `departments:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "departments"
                ],
                "summary": "Create.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDepartments"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDepartments"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/departments/{id}": {
            "get": {
                "tags": [
                    "departments"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDepartments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "departments"
                ],
                "summary": "Update.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDepartments"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDepartments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "departments"
                ],
                "summary": "Cancel.",
                "x-scope": "payroll:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDepartments"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `departments:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/taxclasses/batch": {
            "post": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "Create many.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTaxclasses"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxclasses": {
            "get": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "List tax classes.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTaxclasses"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `taxclasses:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "Create.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxclasses"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxclasses"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/taxclasses/{id}": {
            "get": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxclasses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "Update.",
                "x-scope": "tax:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTaxclasses"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxclasses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "taxclasses"
                ],
                "summary": "Cancel.",
                "x-scope": "tax:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTaxclasses"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `taxclasses:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemcomparisongroups/batch": {
            "post": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemcomparisongroups"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemcomparisongroups": {
            "get": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "List item comparison groups.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemcomparisongroups"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `itemcomparisongroups:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemcomparisongroups"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemcomparisongroups"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemcomparisongroups/{id}": {
            "get": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemcomparisongroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemcomparisongroups"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemcomparisongroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemcomparisongroups"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemcomparisongroups"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `itemcomparisongroups:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/surveys/batch": {
            "post": {
                "tags": [
                    "surveys"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefSurveys"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/surveys": {
            "get": {
                "tags": [
                    "surveys"
                ],
                "summary": "List surveys.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefSurveys"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `surveys:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "surveys"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSurveys"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSurveys"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/surveys/{id}": {
            "get": {
                "tags": [
                    "surveys"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSurveys"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "surveys"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSurveys"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSurveys"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "surveys"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSurveys"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `surveys:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/quotecomments/batch": {
            "post": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefQuotecomments"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/quotecomments": {
            "get": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "List quote comments.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefQuotecomments"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks `quotecomments:read`.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefQuotecomments"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefQuotecomments"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "That code is already in use.",
                        "x-code": "duplicate"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/quotecomments/{id}": {
            "get": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefQuotecomments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefQuotecomments"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefQuotecomments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "`If-Match` did not match.",
                        "x-code": "stale_record"
                    }
                }
            },
            "delete": {
                "tags": [
                    "quotecomments"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefQuotecomments"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Needs `quotecomments:cancel`.",
                        "x-code": "insufficient_scope"
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ccprocessors": {
            "get": {
                "tags": [
                    "ccprocessors"
                ],
                "summary": "List card processors.",
                "x-scope": "banking:read",
                "x-status": "live",
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCcprocessors"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                },
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ]
            }
        },
        "/ccprocessors/{id}": {
            "get": {
                "tags": [
                    "ccprocessors"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcprocessors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glaccounttypes": {
            "get": {
                "tags": [
                    "glaccounttypes"
                ],
                "summary": "List gl account types.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGlaccounttypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                },
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ]
            }
        },
        "/glaccounttypes/{id}": {
            "get": {
                "tags": [
                    "glaccounttypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlaccounttypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glcategorytypes": {
            "get": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "List gl category types.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefGlcategorytypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                },
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key. Scoped to your company."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` for cancelled only, or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ]
            },
            "post": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "Create.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcategorytypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategorytypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcategorytypes/{id}": {
            "get": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategorytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "Update.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefGlcategorytypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategorytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "Cancel.",
                "x-scope": "glaccounts:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlcategorytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/customers/batch": {
            "post": {
                "tags": [
                    "customers"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Customer"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glcategorytypes/batch": {
            "post": {
                "tags": [
                    "glcategorytypes"
                ],
                "summary": "Create many.",
                "description": "Always answers `207`, one result per item.",
                "x-scope": "glaccounts:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefGlcategorytypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojects/batch": {
            "post": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectsCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojects": {
            "get": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "List projects.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "projectcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojects"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectsCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojects"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "description": "Creates a project. Optionally send `milestones` and `tasks` in the same request: the project is created first, then each child is attached to the new id, all inside one transaction. The response echoes the tree in the order you sent it, with real ids, so you can map your input positions.",
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojects/{id}": {
            "get": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojects"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojects"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojects"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                },
                "description": "Only the fields you send change. **Children cannot be sent here** - `milestones` and `tasks` are create-only (see Conventions). Use the child resource to add, change or cancel one."
            },
            "delete": {
                "tags": [
                    "teamprojects"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojects"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttasks/batch": {
            "post": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasksCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttasks": {
            "get": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "List tasks.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "title",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttasks"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttasksCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasks"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttasks/{id}": {
            "get": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttasks"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                },
                "description": "Only the fields you send change. **Children cannot be sent here** - `milestones` and `tasks` are create-only (see Conventions). Use the child resource to add, change or cancel one."
            },
            "delete": {
                "tags": [
                    "teamprojecttasks"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectmilestones/batch": {
            "post": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectmilestonesCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectmilestones": {
            "get": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "List milestones.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectmilestones"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectmilestonesCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmilestones"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectmilestones/{id}": {
            "get": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmilestones"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectmilestones"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmilestones"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                },
                "description": "Only the fields you send change. **Children cannot be sent here** - `milestones` and `tasks` are create-only (see Conventions). Use the child resource to add, change or cancel one."
            },
            "delete": {
                "tags": [
                    "teamprojectmilestones"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmilestones"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectstatuses/batch": {
            "post": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectstatuses": {
            "get": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "List task statuses.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectstatuses"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectstatuses/{id}": {
            "get": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectstatuses"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectstatuses"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectstatuses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectcategories/batch": {
            "post": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectcategories"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectcategories": {
            "get": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "List project categories.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectcategories"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcategories"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectcategories/{id}": {
            "get": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectcategories"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttags/batch": {
            "post": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttags"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttags": {
            "get": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "List project tags.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttags"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttags"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttags"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttags/{id}": {
            "get": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttags"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttags"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectcomments/batch": {
            "post": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectcommentsCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectcomments": {
            "get": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "List task comments.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectcomments"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectcommentsCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcomments"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectcomments/{id}": {
            "get": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcomments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectcomments"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcomments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectcomments"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectcomments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectchecklists/batch": {
            "post": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectchecklistsCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectchecklists": {
            "get": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "List task checklists.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "title",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectchecklists"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectchecklistsCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectchecklists"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectchecklists/{id}": {
            "get": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectchecklists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectchecklists"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectchecklists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectchecklists"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectchecklists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttimelogs/batch": {
            "post": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttimelogs": {
            "get": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "List time logs.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "employeeid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one employeeid."
                    },
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttimelogs/{id}": {
            "get": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttimelogs"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttimelogs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttemplates/batch": {
            "post": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplatesCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttemplates": {
            "get": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "List project templates.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttemplates"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttemplatesCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplates"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttemplates/{id}": {
            "get": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplates"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttemplates"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplates"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttemplates"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplates"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttemplateitems/batch": {
            "post": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplateitemsCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttemplateitems": {
            "get": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "List template items.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "title",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttemplateitemsCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttemplateitems/{id}": {
            "get": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttemplateitems"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttemplateitems"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectrecurringtasks/batch": {
            "post": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectrecurringtasks": {
            "get": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "List recurring tasks.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "title",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectrecurringtasks/{id}": {
            "get": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectrecurringtasks"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectrecurringtasks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectmembers/batch": {
            "post": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectmembers"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectmembers": {
            "get": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "List project members.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectmembers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectmembers"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmembers"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectmembers/{id}": {
            "get": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmembers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectmembers"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmembers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectmembers"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectmembers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttaskassignees/batch": {
            "post": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskassigneesCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskassignees": {
            "get": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "List task assignees.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskassigneesCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskassignees/{id}": {
            "get": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttaskassignees"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskassignees"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttaskwatchers/batch": {
            "post": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskwatchersCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskwatchers": {
            "get": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "List task watchers.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskwatchersCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskwatchers/{id}": {
            "get": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttaskwatchers"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskwatchers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttaskdependencies/batch": {
            "post": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskdependencies": {
            "get": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "List task dependencies.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaskdependencies/{id}": {
            "get": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttaskdependencies"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaskdependencies"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttasktags/batch": {
            "post": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasktagsCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttasktags": {
            "get": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "List task tag links.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttasktags"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttasktagsCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasktags"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttasktags/{id}": {
            "get": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasktags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttasktags"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasktags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttasktags"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttasktags"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojecttaglinks/batch": {
            "post": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaglinks": {
            "get": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "List project tag links.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojecttaglinks/{id}": {
            "get": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojecttaglinks"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojecttaglinks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectreminders/batch": {
            "post": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectreminders"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectreminders": {
            "get": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "List reminders.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectreminders"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectreminders"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectreminders"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectreminders/{id}": {
            "get": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectreminders"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectreminders"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectreminders"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectreminders"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectreminders"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectautomations/batch": {
            "post": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectautomations"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectautomations": {
            "get": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "List automations.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectautomations"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectautomations"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectautomations"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectautomations/{id}": {
            "get": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectautomations"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectautomations"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectautomations"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectautomations"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectautomations"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectviews/batch": {
            "post": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectviews"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectviews": {
            "get": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "List saved views.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectviews"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectviews"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectviews"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectviews/{id}": {
            "get": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectviews"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectviews"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectviews"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "teamprojectviews"
                ],
                "summary": "Cancel.",
                "x-scope": "projects:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectviews"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectsettings/batch": {
            "post": {
                "tags": [
                    "teamprojectsettings"
                ],
                "summary": "Create many.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefTeamprojectsettings"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectsettings": {
            "get": {
                "tags": [
                    "teamprojectsettings"
                ],
                "summary": "List project settings.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectsettings"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "teamprojectsettings"
                ],
                "summary": "Create.",
                "x-scope": "projects:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectsettings"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectsettings"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/teamprojectsettings/{id}": {
            "get": {
                "tags": [
                    "teamprojectsettings"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectsettings"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "teamprojectsettings"
                ],
                "summary": "Update.",
                "x-scope": "projects:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefTeamprojectsettings"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectsettings"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/teamprojectactivity": {
            "get": {
                "tags": [
                    "teamprojectactivity"
                ],
                "summary": "List task activity.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "genuserid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one genuserid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "teamprojectid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one ."
                    },
                    {
                        "name": "teamprojecttaskid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Filter to one task."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefTeamprojectactivity"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/teamprojectactivity/{id}": {
            "get": {
                "tags": [
                    "teamprojectactivity"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "projects:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefTeamprojectactivity"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/vendors/batch": {
            "post": {
                "tags": [
                    "vendors"
                ],
                "summary": "Create many.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefVendors"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendors": {
            "get": {
                "tags": [
                    "vendors"
                ],
                "summary": "List vendors.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "vendorcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefVendors"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "vendors"
                ],
                "summary": "Create.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendors"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendors"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendors/{id}": {
            "get": {
                "tags": [
                    "vendors"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "vendors"
                ],
                "summary": "Update.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendors"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "vendors"
                ],
                "summary": "Cancel.",
                "x-scope": "vendors:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/vendortypes/batch": {
            "post": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "Create many.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefVendortypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendortypes": {
            "get": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "List vendor types.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefVendortypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "Create.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendortypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendortypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendortypes/{id}": {
            "get": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendortypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "Update.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendortypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendortypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "vendortypes"
                ],
                "summary": "Cancel.",
                "x-scope": "vendors:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendortypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/worktypes/batch": {
            "post": {
                "tags": [
                    "worktypes"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefWorktypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/worktypes": {
            "get": {
                "tags": [
                    "worktypes"
                ],
                "summary": "List work types.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefWorktypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "worktypes"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWorktypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorktypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/worktypes/{id}": {
            "get": {
                "tags": [
                    "worktypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorktypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "worktypes"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWorktypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorktypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "worktypes"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorktypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/carriers/batch": {
            "post": {
                "tags": [
                    "carriers"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCarriersCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/carriers": {
            "get": {
                "tags": [
                    "carriers"
                ],
                "summary": "List carriers.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCarriers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "carriers"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCarriersCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarriers"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/carriers/{id}": {
            "get": {
                "tags": [
                    "carriers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarriers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "carriers"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCarriers"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarriers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "carriers"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarriers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/carrierservices/batch": {
            "post": {
                "tags": [
                    "carrierservices"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCarrierservicesCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/carrierservices": {
            "get": {
                "tags": [
                    "carrierservices"
                ],
                "summary": "List carrier services.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCarrierservices"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "carrierservices"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCarrierservicesCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarrierservices"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/carrierservices/{id}": {
            "get": {
                "tags": [
                    "carrierservices"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarrierservices"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "carrierservices"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCarrierservices"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCarrierservices"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/shiptos/batch": {
            "post": {
                "tags": [
                    "shiptos"
                ],
                "summary": "Create many.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefShiptos"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/shiptos": {
            "get": {
                "tags": [
                    "shiptos"
                ],
                "summary": "List ship-tos.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefShiptos"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "shiptos"
                ],
                "summary": "Create.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefShiptos"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShiptos"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/shiptos/{id}": {
            "get": {
                "tags": [
                    "shiptos"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShiptos"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "shiptos"
                ],
                "summary": "Update.",
                "x-scope": "customers:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefShiptos"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShiptos"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "shiptos"
                ],
                "summary": "Cancel.",
                "x-scope": "customers:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShiptos"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/invoices/batch": {
            "post": {
                "tags": [
                    "invoices"
                ],
                "summary": "Create many.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/InvoiceCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "shipto_mismatch": "The `shiptoid` belongs to a different customer.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invoices/{id}": {
            "get": {
                "tags": [
                    "invoices"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoices"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "invoices"
                ],
                "summary": "Update.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoicesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "invoices"
                ],
                "summary": "Cancel.",
                "x-scope": "invoices:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The current GL period is closed, so a reversal has nowhere to post.",
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/invoicelines/batch": {
            "post": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "Create many.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/InvoicelineCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "invoice_already_posted": "The invoice is posted; its voucher was written for the current total."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invoicelines": {
            "get": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "List invoice lines.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "invoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invoiceid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInvoicelines"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "Create.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoicelineCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Added. `invoicetotal` is the re-derived header total.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/InvoicelineCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "invoice_already_posted": "The invoice is posted; its voucher was written for the current total."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invoicelines/{id}": {
            "get": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoicelines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "invoicelines"
                ],
                "summary": "Update.",
                "x-scope": "invoices:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoicelinesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "invoice_already_posted": "The invoice is posted; its voucher was built from the current figures.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            }
        },
        "/orders/batch": {
            "post": {
                "tags": [
                    "orders"
                ],
                "summary": "Create many.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/OrderCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "cannot_invoice_quote": "The order is still a quote, so there is nothing billable.",
                            "nothing_to_invoice": "Nothing shipped and unbilled remains on the document.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orders": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "List orders.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "ordertype",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one ordertype. One of: fulfillment, service, rental."
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status. One of: quote, unconfirmed, open, partial, billed."
                    },
                    {
                        "name": "orderbycompanyid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderbycompanyid."
                    },
                    {
                        "name": "shiptocompanyid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one shiptocompanyid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "salesmanid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one salesmanid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "onum",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "onum. Partial match, case-insensitive."
                    },
                    {
                        "name": "ponumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "ponumber. Partial match, case-insensitive."
                    },
                    {
                        "name": "ordernumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefOrders"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "orders"
                ],
                "summary": "Create.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrderCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The order was written, and stock committed unless it is a quote.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/OrderCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "cannot_invoice_quote": "The order is still a quote, so there is nothing billable.",
                            "nothing_to_invoice": "Nothing shipped and unbilled remains on the document.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "description": "Creates an order, a quote or a service order - which one is decided by `ordertype` and `status`, not by the URL. Optionally send `lines`, `hours` and `shipments` in the same request: each is attached to the new order inside one transaction. The response echoes the tree in the order you sent it, with real ids, so you can map your input positions.",
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orders/{id}": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrders"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "orders"
                ],
                "summary": "Update.",
                "x-scope": "orders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrdersAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "order_already_billed": "The order has billed quantities so its header is part of an invoice; or, for the service status, the order is fully billed and the screen locks the status there too.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason.",
                            "unknown_value": "statusid or statusoption did not match a service status in this company."
                        }
                    }
                },
                "description": "Only the fields you send change. **Children cannot be sent here** - `lines`, `hours` and `shipments` are create-only (see Conventions). Use the child resource to add, change or remove one. Changing `status` from `quote` to `open` commits inventory for every line and is reported back as an `inventory_committed` warning."
            },
            "delete": {
                "tags": [
                    "orders"
                ],
                "summary": "Cancel.",
                "x-scope": "orders:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/orderlines/batch": {
            "post": {
                "tags": [
                    "orderlines"
                ],
                "summary": "Create many.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/OrderlineCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_shipped": "The order has shipped quantities against it."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orderlines": {
            "get": {
                "tags": [
                    "orderlines"
                ],
                "summary": "List order lines.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "orderid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefOrderlines"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "orderlines"
                ],
                "summary": "Create.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrderlineCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Added. `ordertotal` is re-derived and stock re-committed.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/OrderlineCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_shipped": "The order has shipped quantities against it."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orderlines/{id}": {
            "get": {
                "tags": [
                    "orderlines"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderlines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "orderlines"
                ],
                "summary": "Update.",
                "x-scope": "orders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrderlinesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_shipped": "The line has shipped or been billed.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "orderlines"
                ],
                "summary": "Delete.",
                "description": "Remove a line. `arorderdetail` has no `cancel` column, so the row is deleted and the remaining lines are renumbered - the same thing the order entry screen does. Answers `200` with the recalculated order, never `204`. Refused with `line_has_shipped` once any quantity has shipped.",
                "x-scope": "orders:cancel",
                "x-status": "live",
                "x-harddelete": true,
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice.",
                            "line_has_shipped": "The line has shipped or been billed."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/shipments/batch": {
            "post": {
                "tags": [
                    "shipments"
                ],
                "summary": "Create many.",
                "x-scope": "shipments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/ShipmentCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "cannot_ship_quote": "The order is still a quote, so nothing is committed to ship.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "shipqty_exceeds_remaining": "More than `qtyorder - qtyship` was sent.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/shipments": {
            "get": {
                "tags": [
                    "shipments"
                ],
                "summary": "List shipments.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "locationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one locationid."
                    },
                    {
                        "name": "orderid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderid."
                    },
                    {
                        "name": "invoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invoiceid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefShipments"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "shipments"
                ],
                "summary": "Create.",
                "x-scope": "shipments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ShipmentCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Shipped. Stock has moved.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ShipmentCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "cannot_ship_quote": "The order is still a quote, so nothing is committed to ship.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "shipqty_exceeds_remaining": "More than `qtyorder - qtyship` was sent.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/shipments/{id}": {
            "get": {
                "tags": [
                    "shipments"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShipments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "shipments"
                ],
                "summary": "Update.",
                "x-scope": "shipments:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ShipmentsAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "shipments"
                ],
                "summary": "Cancel.",
                "x-scope": "shipments:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice.",
                            "shipment_already_invoiced": "The shipment has been invoiced; the customer has been billed for it."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/shipmentlines/batch": {
            "post": {
                "tags": [
                    "shipmentlines"
                ],
                "summary": "Create many.",
                "x-scope": "shipments:write",
                "x-status": "unsupported",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefShipmentlines"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "description": "Not supported, for the same reason as POST /shipmentlines: only Arorder_model::ship() withdraws stock. Answers 422 use_shipments_endpoint. Use POST /shipments, which already takes several lines at once."
            }
        },
        "/shipmentlines": {
            "get": {
                "tags": [
                    "shipmentlines"
                ],
                "summary": "List shipment lines.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "ordershipid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one ordershipid."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefShipmentlines"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "shipmentlines"
                ],
                "summary": "Create.",
                "x-scope": "shipments:write",
                "x-status": "unsupported",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefShipmentlines"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShipmentlines"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "description": "Not supported. A shipment line is the record of stock leaving, and only Arorder_model::ship() actually withdraws it - writing the line on its own would claim a movement that never happened. Use POST /shipments, which accepts several lines at once. This endpoint answers 422 use_shipments_endpoint."
            }
        },
        "/shipmentlines/{id}": {
            "get": {
                "tags": [
                    "shipmentlines"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShipmentlines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "shipmentlines"
                ],
                "summary": "Update.",
                "x-scope": "shipments:write",
                "x-status": "unsupported",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefShipmentlines"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefShipmentlines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                },
                "description": "Not supported. A shipment line quantity IS the stock movement; amending it would change the record without moving anything back. Cancel the shipment with DELETE /shipments/{id}, which returns the stock, then ship again. Answers 422 use_shipments_endpoint."
            }
        },
        "/payments/batch": {
            "post": {
                "tags": [
                    "payments"
                ],
                "summary": "Create many.",
                "x-scope": "payments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/PaymentCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/payments": {
            "get": {
                "tags": [
                    "payments"
                ],
                "summary": "List payments.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "invoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invoiceid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPayments"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "payments"
                ],
                "summary": "Create.",
                "x-scope": "payments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PaymentCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Applied, with its GL voucher.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/PaymentCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/payments/{id}": {
            "get": {
                "tags": [
                    "payments"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPayments"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "payments"
                ],
                "summary": "Update.",
                "x-scope": "payments:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PaymentsAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "payments"
                ],
                "summary": "Cancel.",
                "x-scope": "payments:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The current GL period is closed, so a reversal has nowhere to post.",
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/purchaseorders/batch": {
            "post": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Create many.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/PurchaseorderCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/purchaseorders": {
            "get": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "List purchase orders.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status. One of: proposal, open."
                    },
                    {
                        "name": "complete",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one complete."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "locationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one locationid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "ponumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPurchaseorders"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Create.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PurchaseorderCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Raised, numbered by NolaPro.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/PurchaseorderCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "description": "Creates a purchase order, optionally with its `lines`. Omit `ponumber` to have one assigned from the `ponumberseq` sequence under a lock.",
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/purchaseorders/{id}": {
            "get": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPurchaseorders"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Update.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PurchaseordersAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_receipts": "The purchase order has receipts against it.",
                            "po_complete": "The purchase order is marked complete.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                },
                "description": "Only the fields you send change. **Children cannot be sent here** - `lines` are create-only (see Conventions). Use the child resource to add, change or remove one. Changing `status` from `quote` to `open` commits inventory for every line and is reported back as an `inventory_committed` warning."
            },
            "delete": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Cancel.",
                "x-scope": "purchaseorders:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice.",
                            "line_has_receipts": "The purchase order has receipts against it."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/purchaseorderlines/batch": {
            "post": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "Create many.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/PurchaseorderlineCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_receipts": "The purchase order has receipts against it.",
                            "po_complete": "The purchase order is marked complete."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/purchaseorderlines": {
            "get": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "List po lines.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "invpoid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invpoid."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPurchaseorderlines"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "Create.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PurchaseorderlineCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Added. `pototal` is re-derived.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/PurchaseorderlineCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_receipts": "The purchase order has receipts against it.",
                            "po_complete": "The purchase order is marked complete."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/purchaseorderlines/{id}": {
            "get": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPurchaseorderlines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "Update.",
                "x-scope": "purchaseorders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/PurchaseorderlinesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "line_has_receipts": "The purchase order has receipts against it.",
                            "po_complete": "The purchase order is marked complete.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "purchaseorderlines"
                ],
                "summary": "Delete.",
                "description": "Remove a line. `invpodetail` has no `cancel` column, so the row is deleted. Answers `200` with the recalculated purchase order. Refused with `line_has_receipts` once any quantity has been received.",
                "x-scope": "purchaseorders:cancel",
                "x-status": "live",
                "x-harddelete": true,
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice.",
                            "line_has_receipts": "The purchase order has receipts against it.",
                            "po_complete": "The purchase order is marked complete."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/estquotes/batch": {
            "post": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Create many.",
                "x-scope": "estimating:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefEstquotes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/estquotes": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "List estimating quotes.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefEstquotes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Create.",
                "x-scope": "estimating:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEstquotes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/estquotes/{id}": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Update.",
                "x-scope": "estimating:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEstquotes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Cancel.",
                "x-scope": "estimating:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/assets/batch": {
            "post": {
                "tags": [
                    "assets"
                ],
                "summary": "Create many.",
                "x-scope": "assets:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefAssets"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/assets": {
            "get": {
                "tags": [
                    "assets"
                ],
                "summary": "List assets.",
                "x-scope": "assets:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "arinvoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one arinvoiceid."
                    },
                    {
                        "name": "invpoid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invpoid."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefAssets"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "assets"
                ],
                "summary": "Create.",
                "x-scope": "assets:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAssets"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssets"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/assets/{id}": {
            "get": {
                "tags": [
                    "assets"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "assets:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssets"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "assets"
                ],
                "summary": "Update.",
                "x-scope": "assets:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAssets"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssets"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "assets"
                ],
                "summary": "Cancel.",
                "x-scope": "assets:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssets"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/assetcategories/batch": {
            "post": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "Create many.",
                "x-scope": "assets:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefAssetcategories"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/assetcategories": {
            "get": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "List asset categories.",
                "x-scope": "assets:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefAssetcategories"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "Create.",
                "x-scope": "assets:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAssetcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssetcategories"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/assetcategories/{id}": {
            "get": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "assets:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssetcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "Update.",
                "x-scope": "assets:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefAssetcategories"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssetcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "assetcategories"
                ],
                "summary": "Cancel.",
                "x-scope": "assets:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefAssetcategories"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/b2busers/batch": {
            "post": {
                "tags": [
                    "b2busers"
                ],
                "summary": "Create many.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefB2busers"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/b2busers": {
            "get": {
                "tags": [
                    "b2busers"
                ],
                "summary": "List b2b users.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefB2busers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "b2busers"
                ],
                "summary": "Create.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefB2busers"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefB2busers"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/b2busers/{id}": {
            "get": {
                "tags": [
                    "b2busers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefB2busers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "b2busers"
                ],
                "summary": "Update.",
                "x-scope": "customers:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefB2busers"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefB2busers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "b2busers"
                ],
                "summary": "Cancel.",
                "x-scope": "customers:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefB2busers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/serviceordertimes/batch": {
            "post": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "Create many.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefServiceordertimesCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/serviceordertimes": {
            "get": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "List service order time.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "employeeid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one employeeid."
                    },
                    {
                        "name": "orderid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefServiceordertimes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "Create.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefServiceordertimesCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The entry as stored, with the re-derived ordertotal.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceordertimes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-codes": {
                            "invalid_request": "A required field was missing, or hours were zero with no note.",
                            "invalid_type": "A decimal arrived as a JSON number, or an id was not an integer.",
                            "invalid_precision": "More decimal places than the field holds.",
                            "unknown_parameter": "A field outside the accepted set, including the derived ones (totalprice, totalcost, baserate, status, currency)."
                        }
                    },
                    "409": {
                        "description": "The order is in a state that will not accept hours.",
                        "x-codes": {
                            "order_already_billed": "The order has reached billed. The service order screen refuses hours there too."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "hours_require_service_order": "The order is not a service order.",
                            "unknown_value": "The worker, work type, tax class, asset or pay type did not resolve in this company.",
                            "rule_violation": "NolaPro refused the write. `message` carries its reason."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/serviceordertimes/{id}": {
            "get": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceordertimes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "Update.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ServiceordertimesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The entry as it now stands, with the re-derived ordertotal.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefServiceordertimes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-codes": {
                            "invalid_request": "Nothing to change, or a malformed value.",
                            "unknown_parameter": "A field outside the amendable set - including the worker and work type, which are the entry's identity."
                        }
                    },
                    "404": {
                        "description": "No such entry.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The entry is in a state that will not accept this.",
                        "x-codes": {
                            "hours_already_billed": "Billing already converted this entry into an order line.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "unknown_value": "A reference did not resolve in this company.",
                            "rule_violation": "The entry is cancelled, or NolaPro refused the change."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "serviceordertimes"
                ],
                "summary": "Cancel.",
                "x-scope": "orders:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled, with the re-derived ordertotal. Cancelling twice answers 200 again - a retry is safe."
                    },
                    "404": {
                        "description": "No such entry.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The entry cannot be cancelled.",
                        "x-codes": {
                            "hours_already_billed": "Billing already converted this entry into an order line. Credit the invoice and cancel the line first."
                        }
                    }
                }
            }
        },
        "/apbills/batch": {
            "post": {
                "tags": [
                    "apbills"
                ],
                "summary": "Create many.",
                "x-scope": "bills:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/ApbillCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "gl_set_unbalanced": "The signed amounts do not sum to zero.",
                            "period_closed": "The GL period containing the date is closed.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/apbills": {
            "get": {
                "tags": [
                    "apbills"
                ],
                "summary": "List ap bills.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "complete",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one complete."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "invoicenumber",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "invoicenumber. Partial match, case-insensitive."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefApbills"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "apbills"
                ],
                "summary": "Create.",
                "x-scope": "bills:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ApbillCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The bill was written and posted.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApbillCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "gl_set_unbalanced": "The signed amounts do not sum to zero.",
                            "period_closed": "The GL period containing the date is closed.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/apbills/{id}": {
            "get": {
                "tags": [
                    "apbills"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefApbills"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "apbills"
                ],
                "summary": "Update.",
                "x-scope": "bills:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ApbillsAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "apbill_already_posted": "The bill already carries a `voucherid`.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "apbills"
                ],
                "summary": "Cancel.",
                "x-scope": "bills:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The current GL period is closed, so a reversal has nowhere to post.",
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/apbilllines/batch": {
            "post": {
                "tags": [
                    "apbilllines"
                ],
                "summary": "Create many.",
                "x-scope": "bills:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/ApbilllineCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "apbill_already_posted": "The bill already carries a `voucherid`."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "distribution_exceeds_total": "The line would code more than the bill is for.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/apbilllines": {
            "get": {
                "tags": [
                    "apbilllines"
                ],
                "summary": "List ap bill lines.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefApbilllines"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "apbilllines"
                ],
                "summary": "Create.",
                "x-scope": "bills:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ApbilllineCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Coded. `undistributed` is what is still uncoded.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApbilllineCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "apbill_already_posted": "The bill already carries a `voucherid`."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "distribution_exceeds_total": "The line would code more than the bill is for.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/apbilllines/{id}": {
            "get": {
                "tags": [
                    "apbilllines"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefApbilllines"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "apbilllines"
                ],
                "summary": "Update.",
                "x-scope": "bills:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/ApbilllinesAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "apbill_already_posted": "The bill already carries a `voucherid`.",
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "distribution_exceeds_total": "The change would code more than the bill is for.",
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            }
        },
        "/bankdeposits/batch": {
            "post": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Create many.",
                "x-scope": "banking:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefBankdeposits"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/bankdeposits": {
            "get": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "List bank deposits.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefBankdeposits"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Create.",
                "x-scope": "banking:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBankdeposits"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBankdeposits"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/bankdeposits/{id}": {
            "get": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBankdeposits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Update.",
                "x-scope": "banking:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBankdeposits"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBankdeposits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Cancel.",
                "x-scope": "banking:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBankdeposits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/jobs/batch": {
            "post": {
                "tags": [
                    "jobs"
                ],
                "summary": "Create many.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefJobs"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/jobs": {
            "get": {
                "tags": [
                    "jobs"
                ],
                "summary": "List jobs.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "jobcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefJobs"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "jobs"
                ],
                "summary": "Create.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefJobs"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefJobs"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/jobs/{id}": {
            "get": {
                "tags": [
                    "jobs"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefJobs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "jobs"
                ],
                "summary": "Update.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefJobs"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefJobs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "jobs"
                ],
                "summary": "Cancel.",
                "x-scope": "jobs:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefJobs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemvendors/batch": {
            "post": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemvendors"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemvendors": {
            "get": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "List item vendors.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemvendors"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemvendors"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemvendors"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemvendors/{id}": {
            "get": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemvendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemvendors"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemvendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemvendors"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemvendors"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemoptions/batch": {
            "post": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemoptions"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemoptions": {
            "get": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "List item options.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemoptions"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemoptions"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptions"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemoptions/{id}": {
            "get": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemoptions"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemoptions"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemoptiongroups/batch": {
            "post": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemoptiongroups"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemoptiongroups": {
            "get": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "List item option groups.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemoptiongroups"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemoptiongroups"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptiongroups"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemoptiongroups/{id}": {
            "get": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptiongroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemoptiongroups"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptiongroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemoptiongroups"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemoptiongroups"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/contactnames/batch": {
            "post": {
                "tags": [
                    "contactnames"
                ],
                "summary": "Create many.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefContactnames"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/contactnames": {
            "get": {
                "tags": [
                    "contactnames"
                ],
                "summary": "List contacts.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefContactnames"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "contactnames"
                ],
                "summary": "Create.",
                "x-scope": "customers:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefContactnames"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefContactnames"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/contactnames/{id}": {
            "get": {
                "tags": [
                    "contactnames"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefContactnames"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "contactnames"
                ],
                "summary": "Update.",
                "x-scope": "customers:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefContactnames"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefContactnames"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "contactnames"
                ],
                "summary": "Cancel.",
                "x-scope": "customers:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefContactnames"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/pricelevels/batch": {
            "post": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefPricelevels"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/pricelevels": {
            "get": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "List price levels.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPricelevels"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefPricelevels"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPricelevels"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/pricelevels/{id}": {
            "get": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPricelevels"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefPricelevels"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPricelevels"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "pricelevels"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPricelevels"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/prpaytypes/batch": {
            "post": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "Create many.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefPrpaytypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/prpaytypes": {
            "get": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "List pay types.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefPrpaytypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "Create.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefPrpaytypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPrpaytypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/prpaytypes/{id}": {
            "get": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPrpaytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "Update.",
                "x-scope": "payroll:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefPrpaytypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPrpaytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "prpaytypes"
                ],
                "summary": "Cancel.",
                "x-scope": "payroll:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefPrpaytypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/producttypetaxes/batch": {
            "post": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "Create many.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefProducttypetaxes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/producttypetaxes": {
            "get": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "List product tax types.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefProducttypetaxes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "Create.",
                "x-scope": "tax:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefProducttypetaxes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefProducttypetaxes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/producttypetaxes/{id}": {
            "get": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "tax:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefProducttypetaxes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "Update.",
                "x-scope": "tax:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefProducttypetaxes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefProducttypetaxes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "producttypetaxes"
                ],
                "summary": "Cancel.",
                "x-scope": "tax:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefProducttypetaxes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/discounts/batch": {
            "post": {
                "tags": [
                    "discounts"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefDiscounts"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/discounts": {
            "get": {
                "tags": [
                    "discounts"
                ],
                "summary": "List discounts.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefDiscounts"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "discounts"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDiscounts"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDiscounts"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/discounts/{id}": {
            "get": {
                "tags": [
                    "discounts"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDiscounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "discounts"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDiscounts"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDiscounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "discounts"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDiscounts"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/coupons/batch": {
            "post": {
                "tags": [
                    "coupons"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCoupons"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/coupons": {
            "get": {
                "tags": [
                    "coupons"
                ],
                "summary": "List coupons.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCoupons"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "coupons"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCoupons"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCoupons"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/coupons/{id}": {
            "get": {
                "tags": [
                    "coupons"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCoupons"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "coupons"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCoupons"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCoupons"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "coupons"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCoupons"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/leases/batch": {
            "post": {
                "tags": [
                    "leases"
                ],
                "summary": "Create many.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefLeases"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/leases": {
            "get": {
                "tags": [
                    "leases"
                ],
                "summary": "List leases.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefLeases"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "leases"
                ],
                "summary": "Create.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefLeases"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefLeases"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/leases/{id}": {
            "get": {
                "tags": [
                    "leases"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefLeases"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "leases"
                ],
                "summary": "Update.",
                "x-scope": "properties:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefLeases"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefLeases"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "leases"
                ],
                "summary": "Cancel.",
                "x-scope": "properties:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefLeases"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/stages/batch": {
            "post": {
                "tags": [
                    "stages"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefStages"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/stages": {
            "get": {
                "tags": [
                    "stages"
                ],
                "summary": "List stages.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefStages"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "stages"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefStages"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefStages"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/stages/{id}": {
            "get": {
                "tags": [
                    "stages"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefStages"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "stages"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefStages"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefStages"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "stages"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefStages"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/worksubtypes/batch": {
            "post": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "Create many.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefWorksubtypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/worksubtypes": {
            "get": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "List work subtypes.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefWorksubtypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "Create.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWorksubtypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorksubtypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/worksubtypes/{id}": {
            "get": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorksubtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "Update.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWorksubtypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorksubtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "worksubtypes"
                ],
                "summary": "Cancel.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWorksubtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ccterminals/batch": {
            "post": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "Create many.",
                "x-scope": "banking:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefCcterminals"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ccterminals": {
            "get": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "List card terminals.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCcterminals"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "Create.",
                "x-scope": "banking:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCcterminals"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcterminals"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ccterminals/{id}": {
            "get": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcterminals"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "Update.",
                "x-scope": "banking:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefCcterminals"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcterminals"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "ccterminals"
                ],
                "summary": "Cancel.",
                "x-scope": "banking:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcterminals"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itempricespecialdetails/batch": {
            "post": {
                "tags": [
                    "itempricespecialdetails"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItempricespecialdetails"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itempricespecialdetails": {
            "get": {
                "tags": [
                    "itempricespecialdetails"
                ],
                "summary": "List item price specials.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItempricespecialdetails"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itempricespecialdetails"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItempricespecialdetails"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecialdetails"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itempricespecialdetails/{id}": {
            "get": {
                "tags": [
                    "itempricespecialdetails"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecialdetails"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itempricespecialdetails"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItempricespecialdetails"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecialdetails"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/vendororderfroms/batch": {
            "post": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "Create many.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefVendororderfroms"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendororderfroms": {
            "get": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "List vendor order-from addresses.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefVendororderfroms"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "Create.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendororderfroms"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendororderfroms"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/vendororderfroms/{id}": {
            "get": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendororderfroms"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "Update.",
                "x-scope": "vendors:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefVendororderfroms"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendororderfroms"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "vendororderfroms"
                ],
                "summary": "Cancel.",
                "x-scope": "vendors:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefVendororderfroms"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/rmareturns/batch": {
            "post": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "Create many.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefRmareturns"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/rmareturns": {
            "get": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "List rma returns.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "invoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invoiceid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefRmareturns"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "Create.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefRmareturns"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefRmareturns"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/rmareturns/{id}": {
            "get": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefRmareturns"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "Update.",
                "x-scope": "orders:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefRmareturns"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefRmareturns"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "rmareturns"
                ],
                "summary": "Cancel.",
                "x-scope": "orders:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefRmareturns"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/cctransactions": {
            "get": {
                "tags": [
                    "cctransactions"
                ],
                "summary": "List card transactions.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCctransactions"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/cctransactions/{id}": {
            "get": {
                "tags": [
                    "cctransactions"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCctransactions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ccpurchases": {
            "get": {
                "tags": [
                    "ccpurchases"
                ],
                "summary": "List card purchases.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "invpoid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invpoid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCcpurchases"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/ccpurchases/{id}": {
            "get": {
                "tags": [
                    "ccpurchases"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcpurchases"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/extusers": {
            "get": {
                "tags": [
                    "extusers"
                ],
                "summary": "List external users.",
                "x-scope": "users:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefExtusers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/extusers/{id}": {
            "get": {
                "tags": [
                    "extusers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "users:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefExtusers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/invreceives/batch": {
            "post": {
                "tags": [
                    "invreceives"
                ],
                "summary": "Create many.",
                "x-scope": "purchaseorders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefInvreceives"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invreceives": {
            "get": {
                "tags": [
                    "invreceives"
                ],
                "summary": "List po receipts.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "vendorid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one vendorid."
                    },
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "locationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one locationid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "invpoid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invpoid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefInvreceives"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "invreceives"
                ],
                "summary": "Create.",
                "x-scope": "purchaseorders:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefInvreceives"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvreceives"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/invreceives/{id}": {
            "get": {
                "tags": [
                    "invreceives"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvreceives"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "invreceives"
                ],
                "summary": "Update.",
                "x-scope": "purchaseorders:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefInvreceives"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvreceives"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "invreceives"
                ],
                "summary": "Cancel.",
                "x-scope": "purchaseorders:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvreceives"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/draws/batch": {
            "post": {
                "tags": [
                    "draws"
                ],
                "summary": "Create many.",
                "x-scope": "jobs:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefDraws"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/draws": {
            "get": {
                "tags": [
                    "draws"
                ],
                "summary": "List draws.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "invoiceid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one invoiceid."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "name. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefDraws"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "draws"
                ],
                "summary": "Create.",
                "x-scope": "jobs:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDraws"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDraws"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/draws/{id}": {
            "get": {
                "tags": [
                    "draws"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDraws"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "draws"
                ],
                "summary": "Update.",
                "x-scope": "jobs:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefDraws"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDraws"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "draws"
                ],
                "summary": "Cancel.",
                "x-scope": "jobs:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefDraws"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ardailycloses/batch": {
            "post": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "Create many.",
                "x-scope": "payments:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefArdailycloses"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ardailycloses": {
            "get": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "List daily closes.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefArdailycloses"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "Create.",
                "x-scope": "payments:write",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefArdailycloses"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefArdailycloses"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/ardailycloses/{id}": {
            "get": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefArdailycloses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "Update.",
                "x-scope": "payments:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefArdailycloses"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefArdailycloses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "ardailycloses"
                ],
                "summary": "Cancel.",
                "x-scope": "payments:cancel",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefArdailycloses"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itempricespecials/batch": {
            "post": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItempricespecials"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itempricespecials": {
            "get": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "List item price specials.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "jobid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one jobid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItempricespecials"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItempricespecials"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecials"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itempricespecials/{id}": {
            "get": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecials"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItempricespecials"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecials"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itempricespecials"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItempricespecials"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/sites/batch": {
            "post": {
                "tags": [
                    "sites"
                ],
                "summary": "Create many.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefSites"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/sites": {
            "get": {
                "tags": [
                    "sites"
                ],
                "summary": "List sites.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefSites"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "sites"
                ],
                "summary": "Create.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSites"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSites"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/sites/{id}": {
            "get": {
                "tags": [
                    "sites"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "jobs:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSites"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "sites"
                ],
                "summary": "Update.",
                "x-scope": "jobs:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefSites"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSites"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "sites"
                ],
                "summary": "Cancel.",
                "x-scope": "jobs:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefSites"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/units/batch": {
            "post": {
                "tags": [
                    "units"
                ],
                "summary": "Create many.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefUnits"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/units": {
            "get": {
                "tags": [
                    "units"
                ],
                "summary": "List units.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefUnits"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "units"
                ],
                "summary": "Create.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefUnits"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefUnits"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/units/{id}": {
            "get": {
                "tags": [
                    "units"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefUnits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "units"
                ],
                "summary": "Update.",
                "x-scope": "properties:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefUnits"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefUnits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "units"
                ],
                "summary": "Cancel.",
                "x-scope": "properties:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefUnits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/ccterminallogs": {
            "get": {
                "tags": [
                    "ccterminallogs"
                ],
                "summary": "List card terminal logs.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefCcterminallogs"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/ccterminallogs/{id}": {
            "get": {
                "tags": [
                    "ccterminallogs"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCcterminallogs"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/stagetypes": {
            "get": {
                "tags": [
                    "stagetypes"
                ],
                "summary": "List stage types.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "title",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "title. Partial match, case-insensitive."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefStagetypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/stagetypes/{id}": {
            "get": {
                "tags": [
                    "stagetypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefStagetypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/buildings/batch": {
            "post": {
                "tags": [
                    "buildings"
                ],
                "summary": "Create many.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefBuildings"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/buildings": {
            "get": {
                "tags": [
                    "buildings"
                ],
                "summary": "List buildings.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "code",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "code. Partial match, case-insensitive."
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefBuildings"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "buildings"
                ],
                "summary": "Create.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBuildings"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildings"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/buildings/{id}": {
            "get": {
                "tags": [
                    "buildings"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildings"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "buildings"
                ],
                "summary": "Update.",
                "x-scope": "properties:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBuildings"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildings"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "buildings"
                ],
                "summary": "Cancel.",
                "x-scope": "properties:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildings"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/buildingtypes/batch": {
            "post": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "Create many.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefBuildingtypes"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/buildingtypes": {
            "get": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "List building types.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefBuildingtypes"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "Create.",
                "x-scope": "properties:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBuildingtypes"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildingtypes"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/buildingtypes/{id}": {
            "get": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "properties:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildingtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "Update.",
                "x-scope": "properties:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefBuildingtypes"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildingtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "buildingtypes"
                ],
                "summary": "Cancel.",
                "x-scope": "properties:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefBuildingtypes"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/estquotepricelists/batch": {
            "post": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "Create many.",
                "x-scope": "estimating:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefEstquotepricelists"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/estquotepricelists": {
            "get": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "List quote price lists.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefEstquotepricelists"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "Create.",
                "x-scope": "estimating:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEstquotepricelists"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotepricelists"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/estquotepricelists/{id}": {
            "get": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotepricelists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "Update.",
                "x-scope": "estimating:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefEstquotepricelists"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotepricelists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "estquotepricelists"
                ],
                "summary": "Cancel.",
                "x-scope": "estimating:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefEstquotepricelists"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/me": {
            "get": {
                "tags": [
                    "me"
                ],
                "summary": "What this token can do.",
                "description": "Returns the token, its company, its user and every scope on it. **No scope is required** - this is the endpoint you call when a token is not working. A scope whose feature is not active on the install comes back with `usable: false` and the feature named, which answers the most common \"I granted the scope and still get 403\" question without a support ticket.",
                "x-noscope": true,
                "x-status": "live",
                "responses": {
                    "200": {
                        "description": "The token.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Me"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "No token, or not a valid one.",
                        "x-code": "unauthorized"
                    }
                },
                "parameters": []
            }
        },
        "/invoices/{id}/post": {
            "post": {
                "tags": [
                    "invoices"
                ],
                "summary": "Post this invoice to the general ledger.",
                "description": "Writes the GL voucher for a DRAFT invoice - one created with `post: false`.\n\nUntil it is posted an invoice has no voucher, which is exactly what lets `POST /invoicelines` and `PATCH /invoicelines/{id}` change it. Posting closes it: the ledger has been told what the invoice is worth, so its lines stop being amendable.\n\nAn already-posted invoice answers 409 rather than writing a second voucher.",
                "x-action": true,
                "x-scope": "invoices:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Posted. The invoice is `open` and carries its voucher."
                    },
                    "404": {
                        "description": "No invoice with that id in this company.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "Already posted. Nothing was written a second time.",
                        "x-code": "invoice_already_posted"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company.",
                            "period_closed": "The GL period the document posts into is closed, so the voucher has nowhere to go."
                        }
                    }
                }
            }
        },
        "/apbills/{id}/post": {
            "post": {
                "tags": [
                    "apbills"
                ],
                "summary": "Post this bill to the general ledger.",
                "description": "Writes the GL voucher for a DRAFT bill - one created with `post: false`.\n\nA draft bill's distribution can still be changed with `POST /apbilllines` and `PATCH /apbilllines/{id}`. Posting runs `billpost()`, which builds the voucher from that distribution, so the lines must already sum to the bill total - otherwise the voucher would not represent the liability it is filed against.\n\nAn already-posted bill answers 409.",
                "x-action": true,
                "x-scope": "bills:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Posted. The bill carries its voucher."
                    },
                    "404": {
                        "description": "No bill with that id in this company.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "Already posted. Nothing was written a second time.",
                        "x-code": "apbill_already_posted"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company.",
                            "period_closed": "The GL period the document posts into is closed, so the voucher has nowhere to go.",
                            "gl_set_unbalanced": "The distribution lines do not sum to the bill total, so the voucher would not represent the liability it is filed against."
                        }
                    }
                }
            }
        },
        "/orders/{id}/invoice": {
            "post": {
                "tags": [
                    "orders"
                ],
                "summary": "Invoice this order.",
                "description": "Turns shipped-but-unbilled quantity into invoices. **Which engine runs depends on `ordertype`**, and they are not interchangeable:\n\n- `service` - the hours logged against the order are first converted into lines and a shipment, then invoiced. The order becomes `billed`.\n- `fulfillment` - invoices whatever has shipped and not yet been billed. Ship first; there is nothing to invoice otherwise.\n- `rental` - invoices rental periods that have come due.\n\nA quote cannot be invoiced. Convert it to an order first.\n\n**A deposit alone is invoiceable.** `arorder2invoice.php:323-324` admits an order when it has shipped-but-unbilled quantity **or** any `arorder_deposit` row, so an order with a deposit and nothing shipped still produces an invoice.",
                "x-action": true,
                "x-scope": "invoices:write",
                "x-scope-also": "orders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoiceRun"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "One or more invoices were raised.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/InvoiceRunResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "cannot_invoice_quote": "The order is still a quote, so there is nothing billable.",
                            "nothing_to_invoice": "Nothing shipped and unbilled remains on the document.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason.",
                            "unknown_value": "A reference did not resolve in this company."
                        }
                    }
                }
            }
        },
        "/shipments/{id}/invoice": {
            "post": {
                "tags": [
                    "shipments"
                ],
                "summary": "Invoice this shipment.",
                "description": "Not available through the API yet. The single-shipment branch of arorder2invoice.php terminates the request with its own page output, so this cannot be served as JSON without changing page code. Invoice the whole order with POST /orders/{id}/invoice, which is live. This endpoint answers 501 in the meantime.",
                "x-action": true,
                "x-scope": "invoices:write",
                "x-scope-also": "shipments:write",
                "x-status": "planned",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/InvoiceRun"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The invoices created.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefInvoiceRunResult"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No shipment with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "The shipment is cancelled, or already invoiced.",
                        "x-code": "shipment_already_invoiced"
                    },
                    "422": {
                        "description": "Nothing on the shipment is billable.",
                        "x-code": "nothing_to_invoice"
                    }
                }
            }
        },
        "/orderdeposits/batch": {
            "post": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "Create many.",
                "x-scope": "payments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "maxItems": 250,
                                "items": {
                                    "$ref": "#/components/schemas/OrderdepositCreate"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per-row outcome. Read `results`; `created` and `failed` are the counts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/BatchResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "deposit_exceeds_order": "The deposit would exceed what is left on the order.",
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orderdeposits": {
            "get": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "List order deposits.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "orderid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one orderid."
                    },
                    {
                        "name": "rnum",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefOrderdeposits"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "Create.",
                "x-scope": "payments:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrderdepositCreate"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Taken, with its GL voucher.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/OrderdepositCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "deposit_exceeds_order": "The deposit would exceed what is left on the order.",
                            "period_closed": "The GL period containing the date is closed.",
                            "rule_violation": "NolaPro refused the document. `message` carries its reason."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/orderdeposits/{id}": {
            "get": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderdeposits"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "Update.",
                "x-scope": "payments:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/OrderdepositsAmend"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Amended. The whole record as it now stands."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No such record.",
                        "x-codes": {
                            "not_found": "No such record, or it belongs to another company."
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "stale_record": "`If-Match` did not match; someone else changed it first."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "rule_violation": "NolaPro refused the change. `message` carries its reason."
                        }
                    }
                }
            },
            "delete": {
                "tags": [
                    "orderdeposits"
                ],
                "summary": "Cancel.",
                "x-scope": "payments:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Cancelled. Cancelling again returns 200 too - it is idempotent."
                    },
                    "400": {
                        "description": "The request was malformed.",
                        "x-code": "invalid_request"
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "Something already depends on this document - a payment, a shipment, an invoice."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The current GL period is closed, so a reversal has nowhere to post.",
                            "unknown_value": "No such record in this company."
                        }
                    }
                }
            }
        },
        "/itemidentifiers/batch": {
            "post": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemidentifiers"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemidentifiers": {
            "get": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "List item identifier types.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemidentifiers"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemidentifiers"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifiers"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemidentifiers/{id}": {
            "get": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifiers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemidentifiers"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifiers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemidentifiers"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifiers"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemidentifierdetails/batch": {
            "post": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefItemidentifierdetails"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemidentifierdetails": {
            "get": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "List item identifier values.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "itemid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemid."
                    },
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "itemidentifierid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one itemidentifierid."
                    },
                    {
                        "name": "itemidentifiervalue",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemidentifierdetails"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemidentifierdetails"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifierdetails"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/itemidentifierdetails/{id}": {
            "get": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifierdetails"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefItemidentifierdetails"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifierdetails"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "itemidentifierdetails"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifierdetails"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/itemidentifiertransactions": {
            "get": {
                "tags": [
                    "itemidentifiertransactions"
                ],
                "summary": "List identifier movements.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one inventorylocationid."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "description. Partial match, case-insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefItemidentifiertransactions"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            }
        },
        "/itemidentifiertransactions/{id}": {
            "get": {
                "tags": [
                    "itemidentifiertransactions"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefItemidentifiertransactions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/webhooks": {
            "get": {
                "tags": [
                    "webhooks"
                ],
                "summary": "List subscriptions.",
                "x-scope": "setup:read",
                "x-status": "live",
                "responses": {
                    "200": {
                        "description": "Your subscriptions.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefWebhooks"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    }
                ]
            },
            "post": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Create a subscription.",
                "description": "The response is the only time `secret` is returned. Store it before you acknowledge the call.",
                "x-scope": "setup:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhooks"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new subscription, including its secret.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/WebhookCreated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing or malformed.",
                        "x-code": "invalid_request"
                    },
                    "422": {
                        "description": "The subscription was refused. Nothing was created.",
                        "x-codes": {
                            "unsupported_value": "The url is not https, so the payload and its signature would travel in clear.",
                            "unknown_value": "An event name is not in the catalogue."
                        }
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "x-codes": [
                    "unsupported_value",
                    "unknown_value",
                    "invalid_request"
                ]
            }
        },
        "/webhooks/{id}": {
            "get": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Retrieve one subscription.",
                "x-scope": "setup:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The subscription.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWebhooks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No subscription with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Update a subscription.",
                "description": "Change the URL, the event list, or pause it. The secret cannot be read back; send a new one to rotate it.",
                "x-scope": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhooks"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated subscription.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWebhooks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No subscription with that id.",
                        "x-code": "not_found"
                    },
                    "400": {
                        "description": "Nothing to change, or the secret was sent.",
                        "x-codes": {
                            "invalid_request": "Send at least one field to change.",
                            "unknown_parameter": "The secret cannot be changed; create a new subscription."
                        }
                    },
                    "422": {
                        "description": "The change was refused.",
                        "x-codes": {
                            "unsupported_value": "The url is not https.",
                            "unknown_value": "An event name is not in the catalogue."
                        }
                    }
                },
                "x-codes": [
                    "unsupported_value",
                    "unknown_value",
                    "unknown_parameter"
                ]
            },
            "delete": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Cancel a subscription.",
                "x-scope": "setup:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled subscription.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefWebhooks"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No subscription with that id.",
                        "x-code": "not_found"
                    },
                    "409": {
                        "description": "Already cancelled.",
                        "x-code": "cannot_cancel"
                    }
                },
                "x-codes": [
                    "cannot_cancel"
                ]
            }
        },
        "/webhooks/{id}/test": {
            "post": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Send a test delivery.",
                "description": "Delivers a `webhooks.test` event to the subscription URL right now and returns what your endpoint answered, including the status code and the first 500 bytes of the body. Built because \"it is not firing\" is the most common webhook ticket and it is almost always a 500 on the receiving end that nobody could see.",
                "x-action": true,
                "x-scope": "setup:write",
                "x-scope-also": "setup:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "What your endpoint answered.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "responsecode": {
                                            "type": "integer",
                                            "description": "HTTP status your endpoint returned. `0` means we could not connect at all."
                                        },
                                        "responsebody": {
                                            "type": "string",
                                            "maxLength": 500,
                                            "description": "First 500 bytes of the response, to make a 500 diagnosable."
                                        },
                                        "durationms": {
                                            "type": "integer",
                                            "description": "Round trip in milliseconds. Over 10000 and we time out."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The body carried a field this endpoint does not take.",
                        "x-code": "unknown_parameter"
                    },
                    "404": {
                        "description": "The subscription went away between the lookup and the write.",
                        "x-code": "not_found"
                    },
                    "422": {
                        "description": "The id did not resolve to a subscription this token can see.",
                        "x-code": "unknown_value"
                    }
                },
                "x-codes": [
                    "unsupported_value"
                ]
            }
        },
        "/items": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "List items.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one status."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one customerid."
                    },
                    {
                        "name": "itemcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Item code. Partial match."
                    },
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Description. Partial match."
                    },
                    {
                        "name": "categoryid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one category."
                    },
                    {
                        "name": "inventorytype",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "S stocked, N non-stocked, O other charges."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "1-based."
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Default 50, maximum 200."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Find by your own key."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "RFC 3339 UTC timestamp. Returns only records changed since then, **including cancelled ones** - so `cancel` defaults to *any* rather than `false` when this is used. The response carries `_meta.synced_through`; store it and send it back next time."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Items.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/Item"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        },
                                        "_meta": {
                                            "$ref": "#/components/schemas/ListMeta"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "tags": [
                    "items"
                ],
                "summary": "Create.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/Item"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new item.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Item"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    },
                    "403": {
                        "description": "The install is at its licensed item limit.",
                        "x-code": "record_limit_reached"
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/items/{id}": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The item.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Item"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No item with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "items"
                ],
                "summary": "Update.",
                "x-scope": "items:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/Item"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated item.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Item"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No item with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "items"
                ],
                "summary": "Cancel.",
                "x-scope": "items:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled item.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Item"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No item with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/items/batch": {
            "post": {
                "tags": [
                    "items"
                ],
                "summary": "Create many.",
                "x-scope": "items:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Item"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                },
                "parameters": [
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ]
            }
        },
        "/glaccounts/{id}/balance": {
            "get": {
                "tags": [
                    "glaccounts"
                ],
                "summary": "Account balance, per currency.",
                "description": "Replaces v1's account-balance action. Computed by `Glaccount_model::getBalance()` - the same code the Trial Balance uses, so the number here and the number on the report cannot disagree.\n\nOptional `asofdate` picks a different point in time; it defaults to the end of the current GL period.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The GL account id."
                    },
                    {
                        "name": "asofdate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "format": "date"
                        },
                        "description": "Defaults to the end of the current GL period."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Balances by currency.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlaccountBalance"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No account with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/glaccounts/{id}/activity": {
            "get": {
                "tags": [
                    "glaccounts"
                ],
                "summary": "Posted transactions against this account.",
                "description": "The detail lines behind [`/glaccounts/{id}/balance`](#get-glaccounts-id-balance), newest first.\n\n**Posted lines only.** An unposted voucher is not part of the balance, so including it here would give you an activity list that does not add up to the balance on the same page - which is the one thing this endpoint has to get right.\n\nDates filter on the GL period the voucher posted to (`post2date`), not the day it was keyed, for the same reason: that is what the balance is measured against.\n\nAmounts are signed - debits positive, credits negative - and the lines of any one voucher sum to zero.",
                "x-scope": "glaccounts:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The GL account id."
                    },
                    {
                        "name": "fromdate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "format": "date"
                        },
                        "description": "Only lines posted to this period or later."
                    },
                    {
                        "name": "todate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "format": "date"
                        },
                        "description": "Only lines posted to this period or earlier."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Page number, 1-based."
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Rows per page."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Posted lines, newest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefGlaccountActivity"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A date that is not a date, or page 0.",
                        "x-code": "invalid_request"
                    },
                    "404": {
                        "description": "No account with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/customers/{id}/aging": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "Open balance split into aging buckets.",
                "description": "Replaces v1's customer-aging action. Computed by `Customer_model::getAgingSummary()` - the AR Aging report's own code, so this and the report cannot disagree.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    },
                    {
                        "name": "asofdate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "format": "date"
                        },
                        "description": "Defaults to today."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Aging by currency.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefCustomerAging"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No customer with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        },
        "/gltransactions/{id}": {
            "get": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "One journal entry.",
                "description": "The voucher a `POST` created. Its `Location` header points here.",
                "x-scope": "gltransactions:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma-separated extras to embed. Only `custom_fields` is available: the extra fields this install has defined on the record. Off by default, and an unrecognised value is refused rather than ignored. See Conventions."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The voucher.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/GlTransaction"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No voucher with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "Reverse a journal entry.",
                "description": "Unposts the entry, which writes the reversing lines, then cancels the voucher. The ledger keeps both, which is the point.\n\n**There is no `PATCH`.** You do not amend a posted journal entry - you reverse it and post a correct one. An endpoint that edited a posted entry would be a way to make the trial balance disagree with its own history.\n\nIdempotent: an entry that is already cancelled returns `200` and changes nothing. The reversal posts into the CURRENT period, so that is the period which must be open, not the one the original landed in.",
                "x-scope": "gltransactions:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The voucher id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Reversed and cancelled.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/GlTransactionCancelled"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The record is in a state that will not accept this.",
                        "x-codes": {
                            "cannot_cancel": "NolaPro refused to reverse it. `message` carries its reason."
                        }
                    },
                    "422": {
                        "description": "A rule was broken. Nothing was written.",
                        "x-codes": {
                            "period_closed": "The current GL period is closed, so the reversal has nowhere to post.",
                            "unknown_value": "No such voucher in this company."
                        }
                    }
                }
            }
        },
        "/invoices/{id}/pdf": {
            "get": {
                "tags": [
                    "invoices"
                ],
                "summary": "Printed invoice as a PDF",
                "operationId": "getInvoicePdf",
                "description": "The invoice exactly as NolaPro prints it, including any attachments the Document Center is set to combine.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.\n\nA draft is refused with `409 not_posted`: the totals on an unposted invoice can still change, so there is no document to print yet. The screens do not offer it either.",
                "x-scope": "invoices:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The invoice id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The invoice is still a draft."
                    }
                },
                "x-codes": [
                    "not_posted",
                    "not_batchable"
                ]
            }
        },
        "/orders/{id}/pdf": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Order confirmation as a PDF",
                "operationId": "getOrderPdf",
                "description": "The order confirmation exactly as NolaPro prints it, including any Document Center attachments set to combine.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/orders/{id}/quote": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Order as a quote PDF",
                "operationId": "getOrderQuotePdf",
                "description": "The same order rendered as a customer-facing quote rather than a confirmation. Prices and terms are laid out for someone deciding, not for someone who has already ordered.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/orders/{id}/pickticket": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Pick ticket as a PDF",
                "operationId": "getOrderPickTicketPdf",
                "description": "The warehouse pick list for the order: what to pull and from where. Carries no prices, because it goes to the floor rather than to the customer.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/purchaseorders/{id}/pdf": {
            "get": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Purchase order as a PDF",
                "operationId": "getPurchaseOrderPdf",
                "description": "The purchase order as it is sent to the vendor.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/purchaseorders/{id}/checklist": {
            "get": {
                "tags": [
                    "purchaseorders"
                ],
                "summary": "Receiving checklist as a PDF",
                "operationId": "getPurchaseOrderChecklistPdf",
                "description": "The receiving checklist for the order: what to expect and tick off as it arrives. Carries no costs, because it goes to the dock.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "purchaseorders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/customers/{id}/statement": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "Customer statement as a PDF",
                "operationId": "getCustomerStatementPdf",
                "description": "The account statement, covering the last twelve months.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/bankdeposits/{id}/pdf": {
            "get": {
                "tags": [
                    "bankdeposits"
                ],
                "summary": "Deposit slip as a PDF",
                "operationId": "getBankDepositPdf",
                "description": "The deposit slip listing everything banked together.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "banking:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/gltransactions/{id}/pdf": {
            "get": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "Journal entry as a PDF",
                "operationId": "getGlTransactionPdf",
                "description": "The journal entry behind a voucher, with both sides of every line.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "gltransactions:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/shipments/{id}/pdf": {
            "get": {
                "tags": [
                    "shipments"
                ],
                "summary": "Packing slip as a PDF",
                "operationId": "getShipmentPdf",
                "description": "The packing slip for the shipment: what is in the boxes, without prices.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/shipments/{id}/boxlabels": {
            "get": {
                "tags": [
                    "shipments"
                ],
                "summary": "Box labels as a PDF",
                "operationId": "getShipmentBoxLabelsPdf",
                "description": "Shipping labels for the cartons in this shipment, laid out for a label printer.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "shipments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/items/{id}/labels": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Barcode shelf labels as a PDF",
                "operationId": "getItemLabelsPdf",
                "description": "A sheet of scannable shelf labels for the item. This is the label SHEET; `GET /items/{id}/barcode` returns a single barcode as a PNG instead.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/orders/{id}/serviceticket": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Service ticket as a PDF",
                "operationId": "getOrderServiceTicketPdf",
                "description": "The service ticket for a service order: the work to be done and the details the technician needs on site.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/estquotes/{id}/packingslip": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Packing slip as a PDF",
                "operationId": "getEstquotePackingSlipPdf",
                "description": "The packing slip for the print order this quote belongs to. Keyed by the quote you already have an id for; the print order behind it is resolved for you.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.\n\nA quote with no print order yet is refused with `409 not_posted` - there is no job to print until one is scheduled.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The quote has no print order yet."
                    }
                },
                "x-codes": [
                    "not_posted",
                    "not_batchable"
                ]
            }
        },
        "/estquotes/{id}/jobticket": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Job ticket as a PDF",
                "operationId": "getEstquoteJobTicketPdf",
                "description": "The shop travelling ticket: what to run, on what stock, in what order.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.\n\nA quote with no print order yet is refused with `409 not_posted` - there is no job to print until one is scheduled.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The quote has no print order yet."
                    }
                },
                "x-codes": [
                    "not_posted",
                    "not_batchable"
                ]
            }
        },
        "/estquotes/{id}/addressform": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Mailing address form as a PDF",
                "operationId": "getEstquoteAddressFormPdf",
                "description": "The addressing and mailing form for the print order.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.\n\nA quote with no print order yet is refused with `409 not_posted` - there is no job to print until one is scheduled.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The quote has no print order yet."
                    }
                },
                "x-codes": [
                    "not_posted",
                    "not_batchable"
                ]
            }
        },
        "/payments/{id}/receipt": {
            "get": {
                "tags": [
                    "payments"
                ],
                "summary": "Payment receipt as a PDF",
                "operationId": "getPaymentReceiptPdf",
                "description": "The receipt for a payment, covering every invoice its voucher settled.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.\n\nA payment with no voucher is refused with `409 not_posted`.",
                "x-scope": "payments:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The invoice id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "The invoice is still a draft."
                    }
                },
                "x-codes": [
                    "not_posted",
                    "not_batchable"
                ]
            }
        },
        "/orders/{id}/proofrequest": {
            "get": {
                "tags": [
                    "orders"
                ],
                "summary": "Paper/mylar proof request as a PDF",
                "operationId": "getOrderProofRequestPdf",
                "description": "The proof request that goes with the order to the plate room.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/customers/{id}/invoicestatus": {
            "get": {
                "tags": [
                    "customers"
                ],
                "summary": "Customer invoice status as a PDF",
                "operationId": "getCustomerInvoiceStatusPdf",
                "description": "Where each of the customer’s orders and invoices currently stands.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "customers:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The customer id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/vendors/{id}/form1099": {
            "get": {
                "tags": [
                    "vendors"
                ],
                "summary": "1099 form as a PDF",
                "operationId": "getVendor1099Pdf",
                "description": "The 1099-MISC for the vendor. Defaults to last tax year.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "vendors:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    },
                    {
                        "name": "taxyear",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Four-digit tax year. Defaults to last year."
                    },
                    {
                        "name": "formtype",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Form variant, e.g. `MISC`."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/estquotes/{id}/boxlabel": {
            "get": {
                "tags": [
                    "estquotes"
                ],
                "summary": "Box labels as a PDF",
                "operationId": "getEstquoteBoxLabelPdf",
                "description": "Carton labels for the print order this quote belongs to.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "estimating:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/items/pricelist": {
            "get": {
                "tags": [
                    "items"
                ],
                "summary": "Price list as a PDF",
                "operationId": "getItemPriceListPdf",
                "description": "The price list across the catalogue. A report over every item, so it takes filters rather than an id.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "items:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "inventorylocationid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one stocking location."
                    },
                    {
                        "name": "categoryid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Restrict to one category."
                    },
                    {
                        "name": "customerid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Price it as this customer would see it."
                    },
                    {
                        "name": "pricelevelid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Price it at this level."
                    },
                    {
                        "name": "begincode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Start of an item-code range."
                    },
                    {
                        "name": "endcode",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "End of an item-code range."
                    },
                    {
                        "name": "showavailable",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Include the available quantity column. `true` or `false`."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/gltransactions/incomestatement": {
            "get": {
                "tags": [
                    "gltransactions"
                ],
                "summary": "Income statement as a PDF",
                "operationId": "getIncomeStatementPdf",
                "description": "The profit and loss statement for a period. Defaults to the year to date.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "gltransactions:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "begindate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Start of the period, `YYYY-MM-DD`. Defaults to 1 January."
                    },
                    {
                        "name": "enddate",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "End of the period, `YYYY-MM-DD`. Defaults to today."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/apbills/checks": {
            "get": {
                "tags": [
                    "apbills"
                ],
                "summary": "Re-print an AP cheque as a PDF",
                "operationId": "getApCheckPdf",
                "description": "Re-draws a cheque that has already been written. **Nothing is recorded** — no cheque number is consumed and no record changes; this renders what is already in the books.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "bills:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "checknbr",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The cheque to draw."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/premployees/checks": {
            "get": {
                "tags": [
                    "premployees"
                ],
                "summary": "Re-print a payroll cheque as a PDF",
                "operationId": "getPayrollCheckPdf",
                "description": "Re-draws a payroll cheque that has already been written. Records nothing.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "checknbr",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The cheque to draw."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/premployees/w2": {
            "get": {
                "tags": [
                    "premployees"
                ],
                "summary": "W-2 forms as a PDF",
                "operationId": "getW2Pdf",
                "description": "The W-2 run for a tax year, covering every employee paid in it.\n\nAnswers `application/pdf`, not JSON. Because the body is binary it cannot be carried inside a `/batch` results array; asking for it there returns `415 not_batchable`.",
                "x-scope": "payroll:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "year",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Four-digit tax year. Defaults to last year."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The rendered PDF.",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    }
                },
                "x-codes": [
                    "not_batchable"
                ]
            }
        },
        "/requestlog": {
            "get": {
                "tags": [
                    "requestlog"
                ],
                "summary": "Read this token's own request log.",
                "description": "Every request this token made, newest first, so \"it returned a 422 and I did not keep the body\" is answerable without asking us.\n\n**Two limits worth knowing before you rely on it.** Logging is off unless it is switched on for the token, and only the **last 100 requests** are kept - it is a recent-history window for debugging, not an audit trail. If you need one of those, record the `X-Request-Id` on your own side as you go.\n\nA token only ever sees its own requests. There is no way to read another token's, including one belonging to the same user in the same company.",
                "x-scope": "setup:read",
                "x-status": "live",
                "x-handbuilt": true,
                "responses": {
                    "200": {
                        "description": "Recent requests made with this token.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RequestLogEntry"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "httpstatus",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Only this HTTP status, e.g. `422`. Named to match the field it filters."
                    },
                    {
                        "name": "failed",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Pass `true` for everything that was not a 2xx."
                    },
                    {
                        "name": "route",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Substring match on the route pattern, e.g. `invoices`."
                    },
                    {
                        "name": "method",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "One HTTP verb."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "1-based."
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Default 50, maximum 200 - though only the last 100 requests are kept, so a larger page cannot return more."
                    }
                ]
            }
        },
        "/webhooks/{id}/flush": {
            "post": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Deliver this subscription's queue now.",
                "description": "Runs the delivery lane for this subscription immediately instead of waiting for the next five-minute cycle, and **clears any remaining retry wait** first.\n\nThat second part is the point. If your endpoint was down and you have just fixed it, the event at the head of the queue may be sitting out a retry gap, and everything behind it is waiting on that event. Flushing drops the wait and sends in order from wherever the queue stands.\n\nOrder is preserved exactly as it is on a normal cycle: delivery stops at the first failure, and nothing behind a failing event is sent.",
                "x-scope": "setup:write",
                "x-status": "live",
                "x-handbuilt": true,
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "What the run did.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/WebhookFlushResult"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The body carried a field this endpoint does not take.",
                        "x-code": "unknown_parameter"
                    },
                    "404": {
                        "description": "The subscription went away between the lookup and the write.",
                        "x-code": "not_found"
                    },
                    "422": {
                        "description": "The id did not resolve to a subscription this token can see.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/webhooks/{id}/deliveries": {
            "get": {
                "tags": [
                    "webhooks"
                ],
                "summary": "What we tried to send, and what your endpoint said.",
                "description": "Every delivery attempt for this subscription, newest first, with the status code and the first 500 bytes your endpoint returned.\n\nThis is the answer to \"the webhook is not firing\". It is almost always a 500 on the receiving end that never reached your own logs, and this shows it without anyone having to reproduce the problem.\n\nDelivered attempts are kept **7 days**; ones that were dropped are kept **30 days**, because a failure is what you need to look at later.",
                "x-scope": "setup:read",
                "x-status": "live",
                "x-handbuilt": true,
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The subscription."
                    },
                    {
                        "name": "delivered",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "`true` for successes, `false` for everything still owed or dropped."
                    },
                    {
                        "name": "abandoned",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "`true` for events that ran out of attempts and were dropped."
                    },
                    {
                        "name": "eventtype",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "One event name, e.g. `orders.created`."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "perpage",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Recent delivery attempts.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/WebhookDelivery"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhooks/{id}/rotatesecret": {
            "post": {
                "tags": [
                    "webhooks"
                ],
                "summary": "Issue a new signing secret.",
                "description": "Mints a new secret and returns it **once**, the same rule as create.\n\n**Both secrets sign for 24 hours by default**, and that is the point rather than a nicety. You cannot change your stored secret at the same instant we change ours, so a straight swap guarantees a window where every delivery fails your signature check - and an event that runs out of attempts is dropped, not delayed. During the overlap `NP-Signature` carries two `v1` values, **the old one first**, so a receiver that reads only the first keeps working untouched until you deploy.\n\nSend `{\"immediate\": true}` to skip the overlap if you can deploy the new secret atomically. Most cannot, which is why it is not the default.",
                "x-scope": "setup:write",
                "x-status": "live",
                "x-handbuilt": true,
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "$ref": "#/components/parameters/IdempotencyKey"
                    }
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "immediate": {
                                        "type": "boolean",
                                        "description": "Retire the old secret at once instead of after 24 hours.",
                                        "x-synthetic": true
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The new secret, shown once.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/WebhookRotated"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "The body carried a field this endpoint does not take.",
                        "x-code": "unknown_parameter"
                    },
                    "404": {
                        "description": "The subscription went away between the lookup and the write.",
                        "x-code": "not_found"
                    },
                    "422": {
                        "description": "The id did not resolve to a subscription this token can see.",
                        "x-code": "unknown_value"
                    }
                }
            }
        },
        "/orderstatusoptions/batch": {
            "post": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "Create many.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/RefOrderstatusoptions"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "207": {
                        "description": "Per item results."
                    }
                }
            }
        },
        "/orderstatusoptions": {
            "get": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "List service order statuses.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "description",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Partial match, case insensitive."
                    },
                    {
                        "name": "cancel",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Defaults to `false`. Pass `true` or `any`."
                    },
                    {
                        "name": "modifiedsince",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Delta polling."
                    },
                    {
                        "name": "externalid",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact match on your own key."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The records.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "required": [
                                        "data",
                                        "page",
                                        "perpage",
                                        "total"
                                    ],
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/RefOrderstatusoptions"
                                            }
                                        },
                                        "page": {
                                            "type": "integer",
                                            "description": "1-based."
                                        },
                                        "perpage": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer",
                                            "description": "Total matching records, not just this page."
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Token lacks read scope.",
                        "x-code": "insufficient_scope"
                    }
                }
            },
            "post": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "Create.",
                "x-scope": "orders:write",
                "x-status": "live",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefOrderstatusoptions"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderstatusoptions"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "A required field was missing.",
                        "x-code": "invalid_request"
                    }
                }
            }
        },
        "/orderstatusoptions/{id}": {
            "get": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "Retrieve one record.",
                "x-scope": "orders:read",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderstatusoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "patch": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "Update.",
                "x-scope": "orders:write",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefOrderstatusoptions"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The updated record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderstatusoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            },
            "delete": {
                "tags": [
                    "orderstatusoptions"
                ],
                "summary": "Cancel.",
                "x-scope": "orders:cancel",
                "x-status": "live",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        },
                        "description": "The record id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The cancelled record.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/RefOrderstatusoptions"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "No record with that id.",
                        "x-code": "not_found"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "Customer": {
                "type": "object",
                "description": "A customer. The stored row has 177 columns and the API exposes 168 of them - the nine holding bank details and integration credentials are never returned and never accepted. The fields below are the documented core; the rest pass through under their own column names. Field names are the column names, so what you see here is what the database calls it.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1187
                    },
                    "companyname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The customer name. Required on create. Not unique, and not a lookup key - use `customercode`.",
                        "x-example": "Summit Retail LLC"
                    },
                    "companyname2": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Second name line.",
                        "x-example": ""
                    },
                    "customercode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Your short code for this customer, and the key the `customer` reference field resolves against. About a quarter of customers have none.",
                        "x-example": "SUMMIT-01"
                    },
                    "chargecode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Charge code shown beside the name in some screens.",
                        "x-example": ""
                    },
                    "displayname": {
                        "type": "string",
                        "maxLength": 255,
                        "readOnly": true,
                        "description": "Generated by the database from the name and code. Read-only.",
                        "x-example": "Summit Retail LLC (SUMMIT-01)"
                    },
                    "fullname": {
                        "type": "string",
                        "maxLength": 255,
                        "readOnly": true,
                        "description": "Generated by the database. Read-only.",
                        "x-example": "Summit Retail LLC"
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address.",
                        "x-example": "900 Industrial Pkwy"
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line.",
                        "x-example": ""
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the billing address.",
                        "x-example": "Fostoria"
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State or province.",
                        "x-example": "OH"
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code.",
                        "x-example": "44830"
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the billing address.",
                        "x-example": "US"
                    },
                    "phone1": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Primary phone.",
                        "x-example": "419-435-0404"
                    },
                    "email1": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Primary email. Where invoices go unless `email2sendinvoices` says otherwise.",
                        "x-example": "ap@summitretail.example"
                    },
                    "email2": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Secondary email.",
                        "x-example": ""
                    },
                    "website": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Customer’s website URL.",
                        "x-example": ""
                    },
                    "creditlimit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Zero means no limit. Stored as a `double`, not `DECIMAL(19,4)` - see Conventions on money.",
                        "x-example": "25000.0000"
                    },
                    "invoicetermsid": {
                        "type": "integer",
                        "description": "Terms id. Defaulted from the company setting when omitted on create.",
                        "x-example": 112
                    },
                    "invoiceterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Terms code, matched against `invoiceterms.verbal`. Send this or `invoicetermsid`, not both unless they agree.",
                        "x-example": "Net 30"
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency code for this customer.",
                        "x-example": "USD"
                    },
                    "nocredit": {
                        "type": "boolean",
                        "description": "No credit allowed - this customer pays up front.",
                        "x-example": false
                    },
                    "taxgroupid": {
                        "type": "integer",
                        "description": "Tax group applied to the customer’s sales.",
                        "x-example": 4
                    },
                    "taxgroup": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Tax group code instead of the id.",
                        "x-example": "OH-SEN"
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Tax exemption id, 0 for none.",
                        "x-example": 0
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Tax exemption name (`taxexempt.exemptname`) instead of the id.",
                        "x-example": "Resale"
                    },
                    "salestaxnum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Sales tax registration number.",
                        "x-example": ""
                    },
                    "salesmanid": {
                        "type": "integer",
                        "description": "Salesperson id.",
                        "x-example": 3
                    },
                    "salesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Salesperson name (`salesman.name`) instead of the id.",
                        "x-example": "Sales Person"
                    },
                    "salesglacctid": {
                        "type": "integer",
                        "description": "Sales GL account id, 0 to use the company default.",
                        "x-example": 0
                    },
                    "salesglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "GL account NUMBER (`glaccount.name`) instead of the id.",
                        "x-example": "4000"
                    },
                    "groupid": {
                        "type": "integer",
                        "description": "Customer group id. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled by `DELETE`. Hidden from lists unless you ask for it.",
                        "x-example": false
                    },
                    "closed": {
                        "type": "boolean",
                        "description": "The relationship has ended. Not the same as cancelled.",
                        "x-example": false
                    },
                    "on_hold": {
                        "type": "boolean",
                        "description": "Trading is suspended, usually for credit. **Check this before shipping** - an on-hold customer is not cancelled and will otherwise accept orders.",
                        "x-example": false
                    },
                    "on_hold_date": {
                        "type": "string",
                        "readOnly": true,
                        "description": "When the hold was applied.",
                        "format": "date-time"
                    },
                    "default_po": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Default PO number applied to this customer’s orders.",
                        "x-example": ""
                    },
                    "notes": {
                        "type": "string",
                        "description": "Free-text notes. Stored as `longtext`, so there is no practical length limit.",
                        "x-example": "",
                        "x-unbounded": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this customer. Scoped to your company.",
                        "x-example": "crm-8842"
                    },
                    "lastchangedate": {
                        "type": "string",
                        "readOnly": true,
                        "description": "Last modification. Drives `modifiedsince`.",
                        "x-example": "2026-07-31T14:02:11Z",
                        "format": "date-time"
                    }
                }
            },
            "CustomerCreate": {
                "type": "object",
                "required": [
                    "companyname"
                ],
                "description": "`companyname` is the only required field. The company comes from your token and is never sent. Omitting `invoicetermsid` applies the company default and returns a `terms_defaulted` warning.",
                "properties": {
                    "companyname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The customer name. Required on create. Not unique, and not a lookup key - use `customercode`.",
                        "x-example": "Summit Retail LLC"
                    },
                    "companyname2": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Second name line.",
                        "x-example": ""
                    },
                    "customercode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Your short code for this customer, and the key the `customer` reference field resolves against. About a quarter of customers have none.",
                        "x-example": "SUMMIT-01"
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address.",
                        "x-example": "900 Industrial Pkwy"
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line.",
                        "x-example": ""
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the billing address.",
                        "x-example": "Fostoria"
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State or province.",
                        "x-example": "OH"
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code.",
                        "x-example": "44830"
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the billing address.",
                        "x-example": "US"
                    },
                    "phone1": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Primary phone.",
                        "x-example": "419-435-0404"
                    },
                    "email1": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Primary email. Where invoices go unless `email2sendinvoices` says otherwise.",
                        "x-example": "ap@summitretail.example"
                    },
                    "creditlimit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Zero means no limit. Stored as a `double`, not `DECIMAL(19,4)` - see Conventions on money.",
                        "x-example": "25000.0000"
                    },
                    "invoicetermsid": {
                        "type": "integer",
                        "description": "Terms id. Defaulted from the company setting when omitted on create.",
                        "x-example": 112
                    },
                    "invoiceterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Terms code, matched against `invoiceterms.verbal`. Send this or `invoicetermsid`, not both unless they agree.",
                        "x-example": "Net 30"
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency code for this customer.",
                        "x-example": "USD"
                    },
                    "taxgroupid": {
                        "type": "integer",
                        "description": "Tax group applied to the customer’s sales.",
                        "x-example": 4
                    },
                    "taxgroup": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Tax group code instead of the id.",
                        "x-example": "OH-SEN"
                    },
                    "salesmanid": {
                        "type": "integer",
                        "description": "Salesperson id.",
                        "x-example": 3
                    },
                    "salesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Salesperson name instead of the id.",
                        "x-example": "Sales Person"
                    },
                    "default_po": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Default PO number applied to this customer’s orders.",
                        "x-example": ""
                    },
                    "notes": {
                        "type": "string",
                        "description": "Free-text notes. Stored as `longtext`, so there is no practical length limit.",
                        "x-example": "",
                        "x-unbounded": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this customer. Scoped to your company.",
                        "x-example": "crm-8842"
                    },
                    "chargecode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Charge code shown beside the name in some screens.",
                        "x-example": ""
                    },
                    "email2": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Secondary email.",
                        "x-example": ""
                    },
                    "website": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Customer’s website URL.",
                        "x-example": ""
                    },
                    "nocredit": {
                        "type": "boolean",
                        "description": "No credit allowed - this customer pays up front.",
                        "x-example": false
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Tax exemption id, 0 for none.",
                        "x-example": 0
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Tax exemption name (`taxexempt.exemptname`) instead of the id.",
                        "x-example": "Resale"
                    },
                    "salestaxnum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Sales tax registration number.",
                        "x-example": ""
                    },
                    "salesglacctid": {
                        "type": "integer",
                        "description": "Sales GL account id, 0 to use the company default.",
                        "x-example": 0
                    },
                    "salesglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "GL account NUMBER (`glaccount.name`) instead of the id.",
                        "x-example": "4000"
                    },
                    "groupid": {
                        "type": "integer",
                        "description": "Customer group id. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled by `DELETE`. Hidden from lists unless you ask for it.",
                        "x-example": false
                    },
                    "closed": {
                        "type": "boolean",
                        "description": "The relationship has ended. Not the same as cancelled.",
                        "x-example": false
                    },
                    "on_hold": {
                        "type": "boolean",
                        "description": "Trading is suspended, usually for credit. **Check this before shipping** - an on-hold customer is not cancelled and will otherwise accept orders.",
                        "x-example": false
                    }
                }
            },
            "CustomerList": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/Customer"
                        },
                        "description": "This page of results."
                    },
                    "page": {
                        "type": "integer",
                        "description": "1-based page number.",
                        "x-example": 1
                    },
                    "perpage": {
                        "type": "integer",
                        "description": "Page size in effect.",
                        "x-example": 50
                    },
                    "total": {
                        "type": "integer",
                        "description": "Total matching records.",
                        "x-example": 214
                    },
                    "_meta": {
                        "$ref": "#/components/schemas/Meta",
                        "readOnly": true,
                        "description": "Present on `modified_since` requests, carrying the cursor for your next poll."
                    }
                }
            },
            "CustomerBalance": {
                "type": "object",
                "description": "Open receivable for one customer. `balances` is always an array, one entry per currency the customer has open invoices in, because NolaPro tracks the balance per currency rather than converting.",
                "properties": {
                    "customerid": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "The customer.",
                        "x-example": 1187
                    },
                    "creditlimit": {
                        "type": "string",
                        "x-money": true,
                        "description": "One value on the customer, not per currency.",
                        "x-example": "25000.0000"
                    },
                    "balances": {
                        "type": "array",
                        "description": "One entry per currency. Always present, even for a single-currency customer.",
                        "items": {
                            "$ref": "#/components/schemas/CustomerBalanceCurrency"
                        }
                    }
                }
            },
            "Item": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "itemcode": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Item code (SKU) - the human key used across NolaPro."
                    },
                    "compositeitemyesno": {
                        "type": "integer",
                        "description": "1 when the item is a composite built from component items (bill of materials)."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Item description shown on documents and lookups."
                    },
                    "categoryid": {
                        "type": "integer",
                        "description": "Categoryid. Id only.",
                        "x-idonly": true
                    },
                    "stockunitnameid": {
                        "type": "integer",
                        "description": "Stockunitnameid. Id only."
                    },
                    "stockunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `stockunitnameid`, not both unless they agree."
                    },
                    "priceunitnameid": {
                        "type": "integer",
                        "description": "Priceunitnameid. Id only."
                    },
                    "priceunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `priceunitnameid`, not both unless they agree."
                    },
                    "lbsperpriceunit": {
                        "type": "string",
                        "description": "Numeric string. Not money - do not apply currency rounding.",
                        "x-number": true
                    },
                    "priceunitsperstockunit": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "stockunitsperpriceunit": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "inventoryglacctid": {
                        "type": "integer",
                        "description": "Inventoryglacctid. Id only."
                    },
                    "inventoryglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `inventoryglacctid`, not both unless they agree."
                    },
                    "salesglacctid": {
                        "type": "integer",
                        "description": "Salesglacctid. Id only."
                    },
                    "salesglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `salesglacctid`, not both unless they agree."
                    },
                    "width": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "length": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "mwt": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "cogs": {
                        "type": "integer",
                        "description": "Cost of goods sold."
                    },
                    "cogseffectivedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the cost of goods sold figure takes effect."
                    },
                    "middlemanprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "priceeffectivedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the price takes effect."
                    },
                    "status": {
                        "type": "boolean",
                        "description": "True when the item is marked Inactive on the item screens - hidden from lookups, kept for history. Not the same as `cancel`."
                    },
                    "id_item_useinstead": {
                        "type": "integer",
                        "description": "Replacement item to use instead of this one, shown when this item is discontinued."
                    },
                    "invtype": {
                        "type": "integer",
                        "description": "Item type: 1 = physical, 2 = print-on-demand (POD - costed at static cost, no stock tracking), 3 = finished goods. 0 on older records."
                    },
                    "catalogdescription": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Catalogdescription. Stored as `text`, no practical length limit."
                    },
                    "products_website": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Product webpage URL shown in the web store."
                    },
                    "catalogsheeturl": {
                        "type": "string",
                        "description": "URL of the item’s catalog sheet, shown in the web store.",
                        "x-unbounded": true
                    },
                    "graphicurl": {
                        "type": "string",
                        "description": "URL or filename of the item’s picture.",
                        "x-unbounded": true
                    },
                    "pdffile": {
                        "type": "string",
                        "description": "PDF file attached to the item for the web store.",
                        "x-unbounded": true
                    },
                    "videofile": {
                        "type": "string",
                        "description": "Video file attached to the item for the web store.",
                        "x-unbounded": true
                    },
                    "soundfile": {
                        "type": "string",
                        "description": "Sound file attached to the item for the web store.",
                        "x-unbounded": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "products_quantity": {
                        "type": "integer",
                        "description": "Quantity mirror maintained in the osCommerce-style web store tables. Maintained by the cart sync, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "products_viewed": {
                        "type": "integer",
                        "description": "View counter maintained by the web store. Cannot be written through the API.",
                        "readOnly": true
                    },
                    "products_status": {
                        "type": "boolean",
                        "description": "Web store visibility flag from the osCommerce-style product tables."
                    },
                    "products_tax_class_id": {
                        "type": "integer",
                        "description": "Legacy osCommerce column. The `products_tax_class` table does not exist in NolaPro and every row holds 0, so this can never resolve to anything. Read-only, and kept only because the column is still on the table.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "products_costprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(8,2)`.",
                        "x-decimals": 2
                    },
                    "products_pushup": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(4,2)`.",
                        "x-decimals": 2
                    },
                    "scart": {
                        "type": "integer",
                        "description": "1 shows the item in the B2B shopping cart."
                    },
                    "parentitemid": {
                        "type": "integer",
                        "description": "Parentitemid. Id only.",
                        "x-idonly": true
                    },
                    "scart_minqtydisplay": {
                        "type": "integer",
                        "description": "Minimum on-hand quantity before the cart shows availability; the Shopify sync maps it to the no-back-orders flag."
                    },
                    "taxexempt": {
                        "type": "boolean",
                        "description": "True when the item is never taxed, regardless of the customer’s tax setup."
                    },
                    "caliper": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "upc": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Universal Product Code."
                    },
                    "author": {
                        "type": "string",
                        "description": "Author, for book and media items in the web store.",
                        "x-unbounded": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "b2b_block": {
                        "type": "boolean",
                        "description": "True blocks the item from B2B orders (Block Usage On B2B Orders)."
                    },
                    "pos_block": {
                        "type": "boolean",
                        "description": "True hides the item from Point of Sale."
                    },
                    "gbaseid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Submission id from the legacy Google Base product feed.",
                        "readOnly": true
                    },
                    "gbasedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the item was last submitted to the legacy Google Base product feed.",
                        "readOnly": true
                    },
                    "commissionflat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "commissionpercent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "staticcost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "minpm": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(6,2)`.",
                        "x-decimals": 2
                    },
                    "restockdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Expected restock date, shown to buyers when the item is out of stock."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "commoditycode": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Commodity Code from the item screen, used on customs and freight paperwork."
                    },
                    "defaultlinenote": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Defaultlinenote. Stored as `text`, no practical length limit."
                    },
                    "inventorytype": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "S = stocked, N = non-stocked, O = other charges. Non-stocked and other-charge items carry no on-hand quantity and cost at static cost."
                    },
                    "last3dcartstockupdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the Shift4Shop (3DCart) sync last pushed a stock level for this item. Maintained by the sync, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "listonebay": {
                        "type": "boolean",
                        "description": "True marks the item for eBay listing (List On eBay)."
                    },
                    "lockpricecost": {
                        "type": "boolean",
                        "description": "True locks price and cost during a sale (Lock Price & Cost During Sale) so line edits cannot change them."
                    },
                    "mobile_pos": {
                        "type": "boolean",
                        "description": "True shows the item in the mobile Point of Sale (Show In Mobile POS)."
                    },
                    "notforsale": {
                        "type": "integer",
                        "description": "1 marks the item Not For Sale - usable internally but blocked from sales documents."
                    },
                    "rental": {
                        "type": "integer",
                        "description": "1 when the item is a rental item."
                    },
                    "shipheight": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shiplength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shippingmarkup": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "shipsbyitself": {
                        "type": "integer",
                        "description": "1 when the item ships in its own package rather than being combined (Ships By Itself)."
                    },
                    "shipwidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "accruedpurchasesglid": {
                        "type": "integer",
                        "description": "GL account purchases accrue to. Write either this or `accruedpurchasesgl`."
                    },
                    "accruedpurchasesgl": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "GL account NUMBER (`glaccount.name`) instead of the id. The sibling of `accruedpurchasesglid`, matching how `salesglacct` and `inventoryglacct` already work on this resource.",
                        "x-example": "4000"
                    },
                    "allownegqtysalesoverride": {
                        "type": "integer",
                        "description": "1 allows negative-quantity sale lines for this item (Allow Negative Quantity Sales), priced by `negativesalesruletype`."
                    },
                    "buyeruserid": {
                        "type": "integer",
                        "description": "Buyeruserid. Id only."
                    },
                    "buyeruser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `buyeruserid`, not both unless they agree."
                    },
                    "expiredays": {
                        "type": "integer",
                        "description": "Shelf life in days; sets the default expiration date when lot tracking receives this item."
                    },
                    "internalbuynotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Internalbuynotes. Stored as `text`, no practical length limit."
                    },
                    "internalsellnotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Internalsellnotes. Stored as `text`, no practical length limit."
                    },
                    "negativesalesruletype": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Pricing rule for negative-quantity sale lines: F = fixed price, R = reduce price by percentage, S = percentage of sale price."
                    },
                    "negativesalesrulevalue": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "nochargeglaccountid": {
                        "type": "integer",
                        "description": "Nochargeglaccountid. Id only."
                    },
                    "nochargeglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `nochargeglaccountid`, not both unless they agree."
                    },
                    "pickernotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Pickernotes. Stored as `text`, no practical length limit."
                    },
                    "po_block": {
                        "type": "integer",
                        "description": "1 blocks the item from purchase orders (Block Usage On Purchase Orders)."
                    },
                    "prelimable": {
                        "type": "boolean",
                        "description": "True when sales of the item count toward preliminary lien notice amounts on prelim-able jobs."
                    },
                    "qtyperpallet": {
                        "type": "integer",
                        "description": "Quantity per pallet; 0 uses the company default."
                    },
                    "rebateglaccountid": {
                        "type": "integer",
                        "description": "Rebateglaccountid. Id only."
                    },
                    "rebateglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `rebateglaccountid`, not both unless they agree."
                    },
                    "rental_d": {
                        "type": "boolean",
                        "description": "True offers daily rental pricing for the item."
                    },
                    "rental_m": {
                        "type": "boolean",
                        "description": "True offers monthly rental pricing for the item."
                    },
                    "rental_w": {
                        "type": "boolean",
                        "description": "True offers weekly rental pricing for the item."
                    },
                    "rentalconverttosalear": {
                        "type": "integer",
                        "description": "GL account credited when a rental converts to a sale (Rental Conversion To Sales)."
                    },
                    "rentalconverttosalecogs": {
                        "type": "integer",
                        "description": "GL account debited for cost when a rental converts to a sale (Rental Conversion Cost Of Goods)."
                    },
                    "returnsglaccountid": {
                        "type": "integer",
                        "description": "Returnsglaccountid. Id only."
                    },
                    "returnsglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `returnsglaccountid`, not both unless they agree."
                    },
                    "transfershortglaccountid": {
                        "type": "integer",
                        "description": "Transfershortglaccountid. Id only."
                    },
                    "transfershortglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `transfershortglaccountid`, not both unless they agree."
                    },
                    "unnumber": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "UN hazardous-material number, printed as a caution on transfer and shipping paperwork."
                    },
                    "itemcodechecksum": {
                        "type": "integer",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it.",
                        "readOnly": true
                    },
                    "itemcomparisongroupid": {
                        "type": "integer",
                        "description": "Itemcomparisongroupid. Id only."
                    },
                    "itemcomparisongroup": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `name` of the referenced itemcomparisongroups, instead of the id. Send this or `itemcomparisongroupid`, not both unless they agree."
                    },
                    "itemidentifiers": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Itemidentifiers. Stored as `text`, no practical length limit."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                },
                "description": "Inventory and non-inventory items. Stock levels are per location and are never written directly, only moved."
            },
            "GlTransactionLine": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "The GL account this line hits.",
                        "x-example": 2309
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "GL account NUMBER (`glaccount.name`) instead of the id.",
                        "x-example": "4000"
                    },
                    "amount": {
                        "type": "string",
                        "description": "Signed. Debits positive, credits negative; the lines of one voucher sum to zero.",
                        "x-example": "-125.0000",
                        "x-money": true
                    },
                    "currency": {
                        "type": "string",
                        "description": "Currency the line posted in.",
                        "maxLength": 10
                    },
                    "transdesc": {
                        "type": "string",
                        "description": "Line narrative as it appears on the voucher.",
                        "maxLength": 255
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job this line is costed to, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "GL category, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "departmentid": {
                        "type": "integer",
                        "description": "Department, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    }
                }
            },
            "ItemTransaction": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "The item that moved.",
                        "x-example": 3391,
                        "x-idonly": true
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location the movement happened at.",
                        "x-example": 2,
                        "x-idonly": true
                    },
                    "trtype": {
                        "type": "integer",
                        "description": "What kind of movement this is. `1` is a commitment against an open order and is deliberately excluded from on-hand; `2` adds stock (a PO receipt is `wherefrom` 6 with `trtype` 2); `3` takes it away (order shipments); `4` is an adjustment. Read from the queries in `includes/invfunctions.php` rather than a declared map, so treat it as the set observed rather than a closed enumeration.",
                        "x-example": 3
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Which module wrote the movement. `1` is AR, `6` is a purchase-order receipt.",
                        "x-example": 1
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Id of the document that caused the movement, within `wherefrom`.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "quantity": {
                        "type": "string",
                        "description": "Signed. Positive adds, negative removes.",
                        "x-example": "-4.000000",
                        "x-qty": true
                    },
                    "costpereach": {
                        "type": "string",
                        "description": "Unit cost carried on this layer.",
                        "x-example": "12.5000",
                        "x-money": true
                    },
                    "pricepereach": {
                        "type": "string",
                        "description": "Unit price, where the movement had one.",
                        "x-example": "19.9900",
                        "x-money": true
                    },
                    "description": {
                        "type": "string",
                        "description": "What the movement was.",
                        "maxLength": 255
                    },
                    "createdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it happened."
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "GL voucher this movement posted through, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled movements stay readable and are excluded from stock."
                    }
                }
            },
            "ApbillPayment": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "apbillid": {
                        "type": "integer",
                        "description": "The bill this paid.",
                        "x-example": 6994,
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "description": "Amount applied to the bill.",
                        "x-example": "250.0000",
                        "x-money": true
                    },
                    "interest": {
                        "type": "string",
                        "description": "Interest paid alongside the principal.",
                        "x-example": "0.0000",
                        "x-money": true
                    },
                    "checkid": {
                        "type": "string",
                        "description": "Cheque number or payment reference.",
                        "maxLength": 100
                    },
                    "checkvoid": {
                        "type": "boolean",
                        "description": "The cheque was voided."
                    },
                    "complete": {
                        "type": "boolean",
                        "description": "The payment run finished."
                    },
                    "paymethod": {
                        "type": "integer",
                        "description": "How it was paid.",
                        "x-example": 1
                    },
                    "currentvoucherid": {
                        "type": "integer",
                        "description": "GL voucher for the payment, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "voidvoucherid": {
                        "type": "integer",
                        "description": "Reversing voucher if it was voided, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the payment was entered."
                    }
                }
            },
            "GlAccountPeriod": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "The account.",
                        "x-example": 2309,
                        "x-idonly": true
                    },
                    "period": {
                        "type": "string",
                        "description": "Accounting period as `YYYYMM` - 202608 is August 2026. Not a date; it is the label NolaPro closes against.",
                        "maxLength": 10
                    },
                    "posted": {
                        "type": "string",
                        "description": "Movement that has been posted in this period.",
                        "x-example": "1250.0000",
                        "x-money": true
                    },
                    "unposted": {
                        "type": "string",
                        "description": "Movement entered but not yet posted.",
                        "x-example": "0.0000",
                        "x-money": true
                    },
                    "yearendadjustments": {
                        "type": "string",
                        "description": "Year-end adjusting entries.",
                        "x-example": "0.0000",
                        "x-money": true
                    },
                    "yearendclose": {
                        "type": "string",
                        "description": "Year-end closing entry.",
                        "x-example": "0.0000",
                        "x-money": true
                    },
                    "currency": {
                        "type": "string",
                        "description": "Currency these totals are held in.",
                        "maxLength": 10
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code the totals are broken down by, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "GL category, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    }
                }
            },
            "ShipmentPackage": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "ordershipid": {
                        "type": "integer",
                        "description": "The shipment this package belongs to.",
                        "x-example": 1248,
                        "x-idonly": true
                    },
                    "tracknumber": {
                        "type": "string",
                        "description": "Carrier tracking number. This is where tracking lives - the order-level audit trail does not carry it.",
                        "maxLength": 100
                    },
                    "weight": {
                        "type": "string",
                        "description": "Package weight.",
                        "x-example": "2.500000",
                        "x-qty": true
                    },
                    "cost": {
                        "type": "string",
                        "description": "Carrier cost for this package.",
                        "x-example": "8.4000",
                        "x-money": true
                    },
                    "arinvoiceid": {
                        "type": "integer",
                        "description": "Invoice the package was billed on, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled packages stay readable."
                    }
                }
            },
            "BankDepositLine": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "bankdepositid": {
                        "type": "integer",
                        "description": "The deposit this line is part of.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Id of the record deposited, within `wherefrom`.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Which module the deposited item came from.",
                        "x-example": 1
                    },
                    "amount": {
                        "type": "string",
                        "description": "Amount of this line.",
                        "x-example": "250.0000",
                        "x-money": true
                    },
                    "deposit_type": {
                        "type": "integer",
                        "description": "What kind of item was deposited.",
                        "x-example": 2
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled lines stay readable."
                    }
                }
            },
            "DocumentNote": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "note": {
                        "type": "string",
                        "description": "The note text.",
                        "x-unbounded": true
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Line the note is against, or 0 for a document-level note.",
                        "x-example": 0
                    },
                    "hide": {
                        "type": "boolean",
                        "description": "Hidden from the printed document."
                    },
                    "private": {
                        "type": "boolean",
                        "description": "Internal only - not shown to the customer."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the note was last changed."
                    }
                }
            },
            "LineTaxDetail": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "salestaxid": {
                        "type": "integer",
                        "description": "The tax that was charged.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "taxamount": {
                        "type": "string",
                        "description": "Tax charged by this jurisdiction on this line.",
                        "x-example": "4.1300",
                        "x-money": true
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Rate applied, as a decimal string. Five places - the column is decimal(12,5), not the 4 that money uses.",
                        "maxLength": 14,
                        "x-decimals": 5,
                        "x-example": "0.08250"
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Exemption applied, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "taxexemptportion": {
                        "type": "string",
                        "description": "Portion of the line that was exempt.",
                        "x-example": "0.0000",
                        "x-money": true
                    }
                }
            },
            "OrderTax": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "The order.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "taxrateid": {
                        "type": "integer",
                        "description": "The tax rate charged.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "tax": {
                        "type": "string",
                        "description": "Tax amount.",
                        "x-example": "12.5000",
                        "x-money": true
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Rate applied, as a decimal string. Five places - the column is decimal(12,5).",
                        "maxLength": 14,
                        "x-decimals": 5,
                        "x-example": "0.08250"
                    },
                    "taxtype": {
                        "type": "integer",
                        "description": "Which kind of tax this is.",
                        "x-example": 0
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Exemption applied, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    }
                }
            },
            "ItemLocationStock": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "The item.",
                        "x-example": 3391,
                        "x-idonly": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "The location.",
                        "x-example": 2,
                        "x-idonly": true
                    },
                    "onhandqty": {
                        "type": "string",
                        "description": "On hand at this location.",
                        "x-example": "412.000000",
                        "x-qty": true
                    },
                    "bin_shelf": {
                        "type": "string",
                        "description": "Bin or shelf within the location.",
                        "maxLength": 100
                    },
                    "minstocklevelseason1": {
                        "type": "string",
                        "description": "Reorder point, season 1.",
                        "x-example": "10.000000",
                        "x-qty": true
                    },
                    "maxstocklevelseason1": {
                        "type": "string",
                        "description": "Maximum stock level, season 1.",
                        "x-example": "100.000000",
                        "x-qty": true
                    },
                    "orderqtyseason1": {
                        "type": "string",
                        "description": "Reorder quantity, season 1.",
                        "x-example": "50.000000",
                        "x-qty": true
                    },
                    "firstcost": {
                        "type": "string",
                        "description": "Cost of the oldest layer.",
                        "x-example": "12.5000",
                        "x-money": true
                    },
                    "lastcost": {
                        "type": "string",
                        "description": "Cost of the newest layer.",
                        "x-example": "13.0000",
                        "x-money": true
                    },
                    "wacost": {
                        "type": "string",
                        "description": "Weighted-average cost at this location.",
                        "x-example": "12.7500",
                        "x-money": true
                    },
                    "lastcounted": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When this location was last counted."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled rows stay readable."
                    }
                }
            },
            "CustomFieldDefinition": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id of the definition."
                    },
                    "key": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The name to use when reading or writing this field's value. Given, not derived. Published from `flexfield.internalname`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "resource": {
                        "type": "string",
                        "maxLength": 60,
                        "description": "The API resource this field is attached to, e.g. `customers`. Published from `flexfield.tablename`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "table": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The underlying table. Published from `flexfield.tablename`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "label": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "What the screens call it. Published from `flexfield.displayname`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "type": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "One of text, select, checkbox, date, radio, textarea, integer, number, file, url, phone. Published from `flexfield.fieldtype`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "required": {
                        "type": "boolean",
                        "description": "The screens refuse to save without it."
                    },
                    "readonly": {
                        "type": "boolean",
                        "description": "Displayed but not editable."
                    },
                    "default": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Value used when none is given. Published from `flexfield.defaultvalue`, not a column of that name.",
                        "x-synthetic": true
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order."
                    },
                    "notes": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Help text shown beside the field."
                    },
                    "options": {
                        "type": "array",
                        "description": "Allowed values, for select and radio fields.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "value": {
                                    "type": "string",
                                    "maxLength": 255,
                                    "description": "What to send."
                                },
                                "label": {
                                    "type": "string",
                                    "x-unbounded": true,
                                    "description": "What to show."
                                }
                            }
                        }
                    }
                }
            },
            "RefInventorycounts": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "type": {
                        "type": "string",
                        "enum": [
                            "cycle",
                            "physical"
                        ],
                        "description": "Cycle counts a subset regularly; physical counts everything. Labels are `Invcountbatch_model::$types`; stored as an int and never exposed as one."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "The location being counted.",
                        "x-example": 2,
                        "x-idonly": true
                    },
                    "invadjustmenttypeid": {
                        "type": "integer",
                        "description": "The adjustment type variance posts through. It carries the GL account, so it decides where a discrepancy lands.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Who the count is assigned to.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "assigneddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it was assigned."
                    },
                    "accepted": {
                        "type": "boolean",
                        "description": "The counter accepted the assignment."
                    },
                    "accepteddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When they accepted."
                    },
                    "complete": {
                        "type": "boolean",
                        "description": "Counting is finished; variance has not necessarily been posted."
                    },
                    "completedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When counting finished."
                    },
                    "posted": {
                        "type": "boolean",
                        "description": "Variance has been posted, turning differences into stock adjustments."
                    },
                    "posteddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it was posted."
                    },
                    "noglpost": {
                        "type": "boolean",
                        "description": "Post the stock movement without a GL entry."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled counts stay readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the batch was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`."
                    }
                }
            },
            "InventoryCountLine": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "invcountbatchid": {
                        "type": "integer",
                        "description": "The batch this line belongs to.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "The item being counted.",
                        "x-example": 3391,
                        "x-idonly": true
                    },
                    "count": {
                        "type": "string",
                        "description": "What was counted. Empty until someone counts it.",
                        "x-example": "42.000000",
                        "x-qty": true
                    },
                    "countset": {
                        "type": "boolean",
                        "description": "A count has actually been entered. Distinguishes a counted zero from an uncounted line, which is the difference between 'there is none' and 'nobody looked'."
                    },
                    "intransit": {
                        "type": "string",
                        "description": "Quantity in transit at the time of the count.",
                        "x-example": "0.000000",
                        "x-qty": true
                    },
                    "status": {
                        "type": "integer",
                        "description": "Where the line is in the count workflow.",
                        "x-example": 0
                    },
                    "countentrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the count was entered."
                    },
                    "assigned_date": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the line was assigned."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the line was added to the batch."
                    }
                }
            },
            "RefInventorytransfers": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "description": "What the transfer is called.",
                        "maxLength": 100
                    },
                    "comment": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 65535
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "newunassigned",
                            "assigned",
                            "accepted",
                            "picked",
                            "shipped",
                            "receivedcompleted"
                        ],
                        "description": "Where the transfer is in its life. Labels are `Invcotransfer_model::$statuses`; stored as an int and never exposed as one."
                    },
                    "gencompanyidfrom": {
                        "type": "integer",
                        "description": "Company sending.",
                        "x-example": 1,
                        "x-idonly": true
                    },
                    "gencompanyidto": {
                        "type": "integer",
                        "description": "Company receiving.",
                        "x-example": 1,
                        "x-idonly": true
                    },
                    "inventorylocationidfrom": {
                        "type": "integer",
                        "description": "Location sending.",
                        "x-example": 2,
                        "x-idonly": true
                    },
                    "inventorylocationidto": {
                        "type": "integer",
                        "description": "Location receiving.",
                        "x-example": 3,
                        "x-idonly": true
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it is due."
                    },
                    "assigneddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it was assigned."
                    },
                    "assigneduserid": {
                        "type": "integer",
                        "description": "Who it is assigned to.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "pickcompleteddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When picking finished."
                    },
                    "shippeddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it shipped."
                    },
                    "receiveddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it was received."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Order that triggered it, or 0.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled transfers stay readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it was raised."
                    },
                    "lastpostdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last time stock moved for it."
                    }
                }
            },
            "InventoryTransferLine": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "description": "NolaPro id."
                    },
                    "invcotransferid": {
                        "type": "integer",
                        "description": "The transfer this line belongs to.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position on the transfer, starting at 1.",
                        "x-example": 1
                    },
                    "itemidfrom": {
                        "type": "integer",
                        "description": "Item as it is known at the sending company.",
                        "x-example": 3391,
                        "x-idonly": true
                    },
                    "itemidto": {
                        "type": "integer",
                        "description": "Item as it is known at the receiving company. The two can differ.",
                        "x-example": 3391,
                        "x-idonly": true
                    },
                    "itemcode": {
                        "type": "string",
                        "description": "Item code at the time of the transfer.",
                        "maxLength": 100
                    },
                    "description": {
                        "type": "string",
                        "description": "Line description.",
                        "maxLength": 255
                    },
                    "quantity": {
                        "type": "string",
                        "description": "Quantity sent.",
                        "x-example": "10.000000",
                        "x-qty": true
                    },
                    "quantityordered": {
                        "type": "string",
                        "description": "Quantity asked for. Compare with `quantity` to see a short send.",
                        "x-example": "12.000000",
                        "x-qty": true
                    },
                    "costeach": {
                        "type": "string",
                        "description": "Unit cost carried across.",
                        "x-example": "12.5000",
                        "x-money": true
                    },
                    "onhandfrom": {
                        "type": "string",
                        "description": "Sender's on-hand at the time.",
                        "x-example": "100.000000",
                        "x-qty": true
                    },
                    "onhandto": {
                        "type": "string",
                        "description": "Receiver's on-hand at the time.",
                        "x-example": "4.000000",
                        "x-qty": true
                    },
                    "picked": {
                        "type": "boolean",
                        "description": "The line has been picked."
                    },
                    "received": {
                        "type": "boolean",
                        "description": "The line has been received. What actually arrived is what `quantity` and the receiving adjustment record; shrinkage lives in the gap between sent and received."
                    },
                    "posted": {
                        "type": "boolean",
                        "description": "Stock has moved for this line."
                    },
                    "postdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the stock moved."
                    },
                    "status": {
                        "type": "integer",
                        "description": "Where the line is in the transfer workflow.",
                        "x-example": 0
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled lines stay readable."
                    }
                }
            },
            "ItemStock": {
                "type": "object",
                "properties": {
                    "itemid": {
                        "type": "integer",
                        "x-example": 3391,
                        "x-idonly": true,
                        "description": " Id only for now - the code sibling is added when items is specced (D22)."
                    },
                    "location": {
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree.",
                        "type": "integer",
                        "x-example": 2
                    },
                    "onhand": {
                        "type": "string",
                        "description": "Decimal string, 6 places. Physically present.",
                        "x-example": "412.000000",
                        "x-qty": true
                    },
                    "committed": {
                        "type": "string",
                        "description": "Allocated to open orders.",
                        "x-example": "60.000000",
                        "x-qty": true
                    },
                    "available": {
                        "type": "string",
                        "description": "`onhand` minus `committed`. What you can promise.",
                        "x-example": "352.000000",
                        "x-qty": true
                    },
                    "cost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Current unit cost at this location, by the company's cost method.",
                        "x-example": "7.1100"
                    }
                }
            },
            "InvoiceCreate": {
                "type": "object",
                "properties": {
                    "customerid": {
                        "type": "integer",
                        "description": "Who is being invoiced.",
                        "x-idonly": true
                    },
                    "date": {
                        "type": "string",
                        "description": "Invoice date. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "post": {
                        "type": "boolean",
                        "description": "Post the invoice to the general ledger. Defaults to true. Send false to create it as a DRAFT: no GL voucher is written, so lines can still be added with POST /invoicelines or changed with PATCH /invoicelines/{id}. Post it later by cancelling and re-raising, or build it fully before posting. Once an invoice carries a voucher its lines are closed to further change.",
                        "default": true,
                        "example": false
                    },
                    "duedate": {
                        "type": "string",
                        "description": "Payment due date. Defaults to the invoice date.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "ponumber": {
                        "type": "string",
                        "description": "The customer's PO number.",
                        "maxLength": 30
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Ship-to company, if different from the customer.",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "description": "Invoice number. Leave it out and NolaPro allocates the next one.",
                        "maxLength": 30
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 1,
                        "items": {
                            "type": "object",
                            "properties": {
                                "itemid": {
                                    "type": "integer",
                                    "description": "Stock item. Omit for a non-stock line and send a description.",
                                    "x-idonly": true
                                },
                                "description": {
                                    "type": "string",
                                    "description": "Line text. Defaults to the item description when itemid is given.",
                                    "maxLength": 255
                                },
                                "quantity": {
                                    "type": "string",
                                    "description": "How many. Decimal STRING, up to 6 places.",
                                    "example": "3.000000",
                                    "x-qty": true
                                },
                                "price": {
                                    "type": "string",
                                    "description": "Unit price. Decimal STRING, not a JSON number.",
                                    "example": "125.0000",
                                    "x-money": true
                                },
                                "taxable": {
                                    "type": "boolean",
                                    "description": "Whether the line attracts tax."
                                }
                            },
                            "required": [
                                "quantity"
                            ]
                        },
                        "description": "At least one line. The tax and the total are derived by NolaPro - do not send them."
                    }
                },
                "required": [
                    "customerid",
                    "lines"
                ],
                "additionalProperties": false
            },
            "InvoiceLine": {
                "type": "object",
                "properties": {
                    "itemid": {
                        "type": "integer",
                        "description": "Omit for a free-text line.",
                        "x-example": 3391
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Item code (`item.itemcode`) instead of the id.",
                        "x-example": "WIDGET-1"
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Defaults to the item description.",
                        "x-example": "Bracket, 4in galvanised"
                    },
                    "quantity": {
                        "type": "string",
                        "description": "Decimal string, 6 places.",
                        "x-example": "24.000000",
                        "x-qty": true
                    },
                    "price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Unit price. Defaults to the customer's price level.",
                        "x-example": "14.2500"
                    },
                    "taxable": {
                        "type": "boolean",
                        "description": "Defaults to the item and customer tax setup.",
                        "x-example": true
                    }
                },
                "required": [
                    "quantity"
                ]
            },
            "Invoice": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "readOnly": true,
                        "x-example": 90412
                    },
                    "number": {
                        "type": "string",
                        "maxLength": 30,
                        "readOnly": true,
                        "description": "Human-facing invoice number.",
                        "x-example": "10442-0"
                    },
                    "customerid": {
                        "description": "Reference to `customers`, by id. Write either this or `customer`.",
                        "type": "integer",
                        "x-example": 104
                    },
                    "date": {
                        "type": "string",
                        "x-example": "2026-08-04",
                        "format": "date"
                    },
                    "subtotal": {
                        "type": "string",
                        "x-money": true,
                        "x-example": "342.0000"
                    },
                    "tax": {
                        "type": "string",
                        "x-money": true,
                        "x-example": "25.6500"
                    },
                    "total": {
                        "type": "string",
                        "x-money": true,
                        "x-example": "367.6500"
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "x-example": "USD"
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "open",
                            "paid",
                            "cancelled"
                        ],
                        "readOnly": true
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "The GL voucher this invoice wrote, or 0 while it is a draft. Payments and bills have always reported theirs; the invoice - the document most likely to be reconciled against another ledger - did not, so there was no way to get from an invoice to its entry. Pair it with `GET /gltransactions/{id}/lines`.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/InvoiceLine"
                        }
                    },
                    "_meta": {
                        "$ref": "#/components/schemas/Meta",
                        "readOnly": true,
                        "description": "Present only when the server has something to report, e.g. the invoice posted but the customer is now over their credit limit."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this record. Indexed, returned on every read, and never interpreted by NolaPro. Use `?externalid=` to look a record up by it instead of by `id`.",
                        "x-example": "crm-8842"
                    },
                    "affectsinventory": {
                        "type": "boolean",
                        "x-nullable": true,
                        "description": "Whether this invoice withdraws stock. **Leave it out.** Omitted, it is derived, and derived is right in every normal case:\n\n- Invoice raised **from an order or shipment** - stock already left at the shipment, so the invoice moves nothing. Sending `true` here is rejected: it would withdraw the same units twice.\n- **Direct invoice** with stocked lines - it withdraws, because nothing else ever will.\n\nSend `false` only when importing history whose stock was already adjusted by another route. The response then carries an `inventory_not_adjusted` warning, because an invoice that sold goods and moved no stock is a discrepancy someone will chase later."
                    }
                }
            },
            "GlTransactionCreate": {
                "type": "object",
                "required": [
                    "date",
                    "lines"
                ],
                "description": "A journal entry: a header and the lines that balance to zero.\n\nThe whole set is written in one transaction. If any line is refused, nothing is written - a half-posted journal entry is not a thing that should be able to exist.",
                "properties": {
                    "date": {
                        "type": "string",
                        "format": "date",
                        "description": "The date the entry posts. Determines the **GL period**, so posting a July-dated entry in August is normal; posting into a closed period is refused with `422 period_closed`. Request-only: stored as `post2date` (the period) and `entrydate`.",
                        "x-synthetic": true
                    },
                    "memo": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Header description, stored as `gltransvoucher.description`. Request-only: stored as `description`.",
                        "x-synthetic": true
                    },
                    "comments": {
                        "type": "string",
                        "maxLength": 50,
                        "x-synthetic": true
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Your own voucher number. NolaPro assigns one when you leave it out.",
                        "x-synthetic": true
                    },
                    "taj": {
                        "type": "boolean",
                        "description": "A year-end tax adjusting entry. These are allowed into a closed MONTH, but never a closed year.",
                        "x-synthetic": true
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own key for this entry. Scoped to your company.",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 2,
                        "description": "At least two. One line is not a journal entry, even when it sums to zero.",
                        "items": {
                            "$ref": "#/components/schemas/GlLine"
                        },
                        "x-synthetic": true
                    }
                }
            },
            "GlLine": {
                "type": "object",
                "required": [
                    "amount"
                ],
                "properties": {
                    "glaccountid": {
                        "type": "integer",
                        "description": "The account to post to. Send this or `glaccount`.",
                        "x-idonly": true
                    },
                    "glaccount": {
                        "type": "string",
                        "description": "The account NUMBER (`glaccount.name`) instead of the id.",
                        "maxLength": 20,
                        "x-synthetic": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "x-decimals": 4,
                        "description": "Signed decimal **string**. Positive debits, negative credits. A JSON number is refused: `0.1` has no exact binary form, so a set that balances in your code can arrive here unbalanced.",
                        "x-synthetic": true
                    },
                    "memo": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Line note, stored as `gltransaction.transdesc`.",
                        "x-synthetic": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job, where the account allows one.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "description": "Cost code.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "glcategoryid": {
                        "description": "Glcategoryid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "departmentid": {
                        "type": "integer",
                        "x-idonly": true
                    }
                }
            },
            "GlTransaction": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Voucher number identifying the entry set."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Description of the journal entry."
                    },
                    "comments": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Free-form comments on the entry."
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Module that wrote the voucher: 1 = AP, 2 = AR, 3 = GL journal entry, 4 = inventory, 6 = payroll."
                    },
                    "status": {
                        "type": "integer",
                        "description": "0 = unposted, 1 = posted, 2 = year-end closing entry.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "standardset": {
                        "type": "boolean",
                        "description": "True when the voucher is a recurring standard journal set - a template that generates entries, not a posted entry itself."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "posteddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the voucher was posted.",
                        "readOnly": true
                    },
                    "post2date": {
                        "type": "string",
                        "format": "date",
                        "description": "The GL period the entry landed in."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "postuserid": {
                        "type": "integer",
                        "description": "Postuserid. Id only."
                    },
                    "postuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `postuserid`, not both unless they agree."
                    },
                    "bankdepositid": {
                        "type": "integer",
                        "description": "Bankdepositid. Id only.",
                        "x-idonly": true
                    },
                    "referencetable": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Table of the document that produced the voucher (arinvoice, apbill, ...); empty for manual journal entries."
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Referenceid. Id only.",
                        "x-idonly": true
                    },
                    "taj": {
                        "type": "boolean",
                        "description": "A year-end tax adjusting entry. These are allowed into a closed MONTH, but never a closed year."
                    },
                    "canceledbyvoucherid": {
                        "type": "integer",
                        "description": "Canceledbyvoucherid. Id only."
                    },
                    "canceledbyvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `canceledbyvoucherid`, not both unless they agree."
                    },
                    "cancelsvoucherid": {
                        "type": "integer",
                        "description": "Cancelsvoucherid. Id only."
                    },
                    "cancelsvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `cancelsvoucherid`, not both unless they agree."
                    },
                    "reversedbyvoucherid": {
                        "type": "integer",
                        "description": "Reversedbyvoucherid. Id only."
                    },
                    "reversedbyvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `reversedbyvoucherid`, not both unless they agree."
                    },
                    "reversesvoucherid": {
                        "type": "integer",
                        "description": "Reversesvoucherid. Id only."
                    },
                    "reversesvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `reversesvoucherid`, not both unless they agree."
                    },
                    "standardsetperiodends": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the recurrence stops."
                    },
                    "standardsetperiodendscount": {
                        "type": "integer",
                        "description": "Stop after this many recurrences."
                    },
                    "standardsetperiodstarts": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the recurrence starts."
                    },
                    "standardsetperiodtype": {
                        "type": "integer",
                        "description": "How the standard set recurs: 0 = manually as needed, 1 = daily, 2 = weekly, 3 = monthly, 4 = yearly."
                    },
                    "standardsetperiodvalue": {
                        "type": "integer",
                        "description": "Recurs every X days/weeks/months/years - this is the X."
                    },
                    "standardsetposthow": {
                        "type": "boolean",
                        "description": "True posts the generated entries as one set; false posts them individually."
                    },
                    "entryday": {
                        "type": "string",
                        "format": "date",
                        "description": "Entry date as a plain date, derived from `entrydate` for period math. Maintained by the model, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "entrymonth": {
                        "type": "string",
                        "format": "date",
                        "description": "First day of the entry month, derived from `entrydate` for period math. Maintained by the model, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "standardsetzeroactivepost2period": {
                        "type": "integer",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/GlLine"
                        }
                    }
                },
                "description": "Direct journal entries. The most powerful endpoint here, and the one with the strictest rules."
            },
            "Warning": {
                "type": "object",
                "description": "A non-fatal notice about a request that succeeded.",
                "properties": {
                    "code": {
                        "type": "string",
                        "description": "Stable, branchable identifier.",
                        "x-example": "credit_limit_exceeded",
                        "x-envelope": true
                    },
                    "field": {
                        "type": "string",
                        "description": "The field the warning concerns, when there is one.",
                        "x-example": "customerid",
                        "x-envelope": true
                    },
                    "message": {
                        "type": "string",
                        "description": "Human-readable. May be reworded; do not parse.",
                        "x-example": "Posted. Customer is now 4,218.55 over their 25,000.00 limit.",
                        "x-envelope": true
                    }
                }
            },
            "Meta": {
                "type": "object",
                "description": "Reserved key for information about the response rather than the resource. Omitted entirely when there is nothing to report — it is never {} or {\"warnings\":[]}.",
                "properties": {
                    "warnings": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/Warning"
                        },
                        "description": "Things that succeeded but you should know about."
                    },
                    "synced_through": {
                        "type": "string",
                        "description": "Server timestamp to use as the next `modified_since`. Present only on requests that used it. Using your own clock instead loses any record written during the previous poll.",
                        "x-example": "2026-08-04T02:19:41Z",
                        "x-envelope": true
                    }
                }
            },
            "Unitname": {
                "type": "object",
                "description": "A unit of measure. This list is **not** company scoped. `unitname` has no company column, so every company on the install shares one set of units and a change here is visible to all of them immediately.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id. This is what item and line records store.",
                        "x-example": 1
                    },
                    "unitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The unit name as it appears on documents. Trimmed on input. Matching is case insensitive, so `each` and `Each` are the same unit.",
                        "x-example": "Each"
                    },
                    "cancel": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "True once cancelled. Cancelled records stay referenced by history and keep their id.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this unit. Unlike the unit itself this **is** per company, so each company can map its own code onto the same shared unit.",
                        "x-example": "EA"
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification. Drives `modifiedsince`.",
                        "x-example": "2026-07-31T14:02:11Z"
                    }
                }
            },
            "CustomerBalanceCurrency": {
                "type": "object",
                "description": "The open balance in one currency, with its aging buckets.",
                "properties": {
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency code.",
                        "x-example": "USD"
                    },
                    "balance": {
                        "type": "string",
                        "x-money": true,
                        "description": "Total open in this currency.",
                        "x-example": "8420.5000"
                    },
                    "overdue": {
                        "type": "string",
                        "x-money": true,
                        "description": "The part of the balance that is past due.",
                        "x-example": "1120.0000"
                    },
                    "buckets": {
                        "type": "object",
                        "description": "Aging buckets. These sum to `balance`.",
                        "properties": {
                            "days0to30": {
                                "type": "string",
                                "x-money": true,
                                "description": "0 to 30 days.",
                                "x-example": "5100.0000"
                            },
                            "days31to60": {
                                "type": "string",
                                "x-money": true,
                                "description": "31 to 60 days.",
                                "x-example": "2200.5000"
                            },
                            "days61to90": {
                                "type": "string",
                                "x-money": true,
                                "description": "61 to 90 days.",
                                "x-example": "1120.0000"
                            },
                            "days91plus": {
                                "type": "string",
                                "x-money": true,
                                "description": "Over 90 days.",
                                "x-example": "0.0000"
                            }
                        }
                    }
                }
            },
            "RefSalesmen": {
                "type": "object",
                "description": "Salespeople and service reps. One table serves both roles - `salesman` and `servicerep` are flags, so filter on those rather than expecting two resources.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 3
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Sales Person"
                    },
                    "salesman": {
                        "type": "boolean",
                        "description": "Acts as a salesperson.",
                        "x-example": true
                    },
                    "servicerep": {
                        "type": "boolean",
                        "description": "Acts as a service rep.",
                        "x-example": false
                    },
                    "commissionrate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Commission percentage.",
                        "x-example": "5.000",
                        "x-decimals": 3
                    },
                    "email1": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Primary email.",
                        "x-example": ""
                    },
                    "phone1": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Primary phone.",
                        "x-example": ""
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this salespeople. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefSalescategories": {
                "type": "object",
                "description": "Sales categories, used to group revenue. Note this table tracks modification in `lastupdatedate`, not `lastchangedate`, so `modifiedsince` reads that column here.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Retail"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this sales categories. Scoped to your company."
                    }
                }
            },
            "RefTaxgroups": {
                "type": "object",
                "description": "Tax groups. Empty on many installs until tax is configured.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 4
                    },
                    "groupcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "OH-SEN"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this tax groups. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefIgroups": {
                "type": "object",
                "description": "Customer groups, the target of `customer.groupid`. Not to be confused with `customergroup`, which is a customer-to-group join table and is not exposed.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 4
                    },
                    "groupcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "DIM"
                    },
                    "groupname": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Full group name.",
                        "x-example": "Dimension Insurance"
                    },
                    "multiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-example": "1.0000",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this customer groups. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefTaskstatuses": {
                "type": "object",
                "description": "Task statuses used by CRM activity. **This table has no `lastchangedate`**, so `modifiedsince` is not offered here.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 3
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Open"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this task statuses. Scoped to your company."
                    }
                }
            },
            "RefEmailtemplates": {
                "type": "object",
                "description": "Templates behind the emails NolaPro sends. `action` is the key that identifies which email a template is for; `name` is the human label. **No `lastchangedate`**, so no `modifiedsince`.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2
                    },
                    "action": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "invoice"
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Human label for the template.",
                        "x-example": "Invoice email"
                    },
                    "subject": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Subject line.",
                        "x-example": ""
                    },
                    "body": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Template body.",
                        "x-example": ""
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this email templates. Scoped to your company."
                    }
                }
            },
            "RefServiceworktypes": {
                "type": "object",
                "description": "Work types for Service Orders. Only populated on installs running that module.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Install"
                    },
                    "color": {
                        "type": "string",
                        "maxLength": 7,
                        "description": "Display colour, hex.",
                        "x-example": "#3366cc"
                    },
                    "defaultlengthminutes": {
                        "type": "integer",
                        "description": "Default duration in minutes.",
                        "x-example": 60
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this service work types. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefTaxableentityusecodes": {
                "type": "object",
                "description": "Taxable entity use codes, used by tax engines to classify why a sale is exempt.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 16,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "A"
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Short label.",
                        "x-example": "Federal government"
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Longer explanation.",
                        "x-example": ""
                    },
                    "validcountries": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Comma separated country codes. A string, not a relation.",
                        "x-example": "US"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this entity use codes. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefInvoiceterms": {
                "type": "object",
                "description": "Payment terms. **The most referenced lookup in the API** - 18,112 of 18,115 customers point at one. Shared install-wide, so a change here is visible to every company.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 112
                    },
                    "verbal": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Net 30"
                    },
                    "netduedays": {
                        "type": "integer",
                        "description": "Days until the full amount is due.",
                        "x-example": 30
                    },
                    "discountpercent": {
                        "type": "string",
                        "description": "Numeric string, 3 decimal places. Not money - do not apply currency rounding.",
                        "x-example": "2.000",
                        "x-decimals": 3,
                        "x-number": true
                    },
                    "discountdays": {
                        "type": "integer",
                        "description": "Days the discount is available for.",
                        "x-example": 10
                    },
                    "ar": {
                        "type": "boolean",
                        "description": "Available on the receivable side.",
                        "x-example": true
                    },
                    "ap": {
                        "type": "boolean",
                        "description": "Available on the payable side.",
                        "x-example": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this invoice terms. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefTaxexempts": {
                "type": "object",
                "description": "Tax exemption reasons and their rates. More than a label - each carries a `state` and a `taxrate`.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "exemptname": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "Resale"
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "State the exemption applies in.",
                        "x-example": "OH"
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Numeric string, 4 decimal places. Not money - do not apply currency rounding.",
                        "x-example": "0.0000",
                        "x-decimals": 4,
                        "x-number": true
                    },
                    "partial": {
                        "type": "boolean",
                        "description": "Partial rather than full exemption.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this tax exemptions. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefAreas": {
                "type": "object",
                "description": "Geographic or sales areas. Empty on many installs.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "North"
                    },
                    "applicationfee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Application fee. Stored with **six** decimals, unlike most money in NolaPro - it is still returned at 4.",
                        "x-example": "0.0000",
                        "x-decimals": 6
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this areas. Scoped to your company."
                    }
                }
            },
            "RefZones": {
                "type": "object",
                "description": "States and provinces. Static reference data - no writes, no cancel flag, no external ids. Its identifier is `zone_id`, because that is what the column is called.",
                "properties": {
                    "zone_id": {
                        "type": "integer",
                        "x-identifier": true,
                        "readOnly": true,
                        "description": "Identifier.",
                        "x-example": 33
                    },
                    "zone_code": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "Short code.",
                        "x-example": "OH"
                    },
                    "zone_name": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Full name.",
                        "x-example": "Ohio"
                    },
                    "zone_country_id": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The country this zone belongs to. Id only - `countries` is read-only reference data with no code sibling.",
                        "x-example": 223
                    }
                }
            },
            "RefCountries": {
                "type": "object",
                "description": "Countries, with the number formatting NolaPro uses for each. The formatting columns are worth reading if you display amounts - they explain why a total renders differently per country.",
                "properties": {
                    "countries_id": {
                        "type": "integer",
                        "x-identifier": true,
                        "readOnly": true,
                        "description": "Identifier.",
                        "x-example": 223
                    },
                    "countries_name": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "Country name.",
                        "x-example": "United States"
                    },
                    "countries_iso_code_2": {
                        "type": "string",
                        "maxLength": 2,
                        "description": "ISO 3166-1 alpha-2.",
                        "x-example": "US"
                    },
                    "countries_iso_code_3": {
                        "type": "string",
                        "maxLength": 3,
                        "description": "ISO 3166-1 alpha-3.",
                        "x-example": "USA"
                    },
                    "calling_code": {
                        "type": "string",
                        "maxLength": 3,
                        "description": "International dialling prefix.",
                        "x-example": "1"
                    },
                    "decimalplaces": {
                        "type": "integer",
                        "description": "Decimal places used when displaying money.",
                        "x-example": 2
                    },
                    "decimalsymbol": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "Decimal separator.",
                        "x-example": "."
                    },
                    "thousandssymbol": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "Thousands separator.",
                        "x-example": ","
                    },
                    "currency_symbol": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "Currency symbol shown for amounts in this country’s currency.",
                        "x-example": "$"
                    },
                    "symbolafter": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "Symbol goes after the amount when set.",
                        "x-example": ""
                    }
                }
            },
            "RefTimezones": {
                "type": "object",
                "description": "IANA time zone names. Static reference data.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Identifier.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "IANA zone name.",
                        "x-example": "America/New_York"
                    }
                }
            },
            "RefMobilecarriers": {
                "type": "object",
                "description": "Mobile carriers and their SMS gateway domains, used for text notifications.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Identifier.",
                        "x-example": 1
                    },
                    "carriername": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the mobile carrier, shown when picking an SMS gateway.",
                        "x-example": "Verizon"
                    },
                    "smsgatewaydomain": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Email-to-SMS gateway domain.",
                        "x-example": "vtext.com"
                    }
                }
            },
            "RefGlaccounts": {
                "type": "object",
                "description": "**`name` holds the account number and `description` holds the label.** That is backwards from most expectations and it is the single most important thing to know about this resource. Scoped per company, on the `companyid` column.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2376
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "4000"
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The account label, despite the column name.",
                        "x-example": "Sales - Retail"
                    },
                    "accounttypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "Account type. See `glaccounttypes` - read-only.",
                        "x-example": 4
                    },
                    "block_journal": {
                        "type": "boolean",
                        "description": "When true this account refuses direct journal entries, and `gltransactions` writes against it are rejected.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this gl accounts. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefInventorylocations": {
                "type": "object",
                "description": "Warehouses and stocking locations. Address-shaped rather than code-shaped. **Carries both `cancel` and `inactive`**, which mean different things - a location can be active but temporarily not stocking. Read-only in this release; creating one has physical inventory consequences.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "locationcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code this resource is keyed by. Matching is case insensitive.",
                        "x-example": "MAIN"
                    },
                    "companyname": {
                        "type": "string",
                        "maxLength": 35,
                        "description": "Location name.",
                        "x-example": "Main Warehouse"
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the location address.",
                        "x-example": "Fostoria"
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the location address.",
                        "x-example": "OH"
                    },
                    "inactive": {
                        "type": "boolean",
                        "description": "Temporarily not in use. Distinct from `cancel`.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this inventory locations. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefInterestchargeoptions": {
                "type": "object",
                "description": "**This table has no name, code or label** - it is an id and a rate. There is therefore no code sibling anywhere that references it, permanently. Read-only.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "rate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Interest rate.",
                        "x-example": "1.5000",
                        "x-decimals": 4
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled. Cancelled rows stay referenced by history.",
                        "x-example": false
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification (`lastchangedate`). Drives `modifiedsince`."
                    }
                }
            },
            "RefGenusers": {
                "type": "object",
                "description": "**Read-only, and deliberately minimal.** Users are who NolaPro attributes work to, so an integrator needs to resolve an id to a name - and nothing more. Credentials, API keys, two-factor secrets and the ninety-odd preference columns are never returned.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "User id. This is what `entryuserid` and friends hold.",
                        "x-example": 2
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "readOnly": true,
                        "description": "Login name.",
                        "x-example": "jsmith"
                    },
                    "firstname": {
                        "type": "string",
                        "maxLength": 35,
                        "readOnly": true,
                        "description": "The user’s first name.",
                        "x-example": "Jane"
                    },
                    "lastname": {
                        "type": "string",
                        "maxLength": 35,
                        "readOnly": true,
                        "description": "The user’s last name.",
                        "x-example": "Smith"
                    },
                    "email": {
                        "type": "string",
                        "maxLength": 100,
                        "readOnly": true,
                        "description": "Email address.",
                        "x-example": "jane@example.com"
                    },
                    "supervisor": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "Supervisor in this company.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "True once the user is cancelled.",
                        "x-example": false
                    }
                }
            },
            "RefPremployees": {
                "type": "object",
                "description": "**Read-only and minimal, for the same reason as users, only more so.** The stored row carries social security numbers, pay rates, bank details and tax withholding. None of that is returned and none of it is writable. This resource exists only so `salesman.payrollid` can be resolved to a name.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Employee id.",
                        "x-example": 5
                    },
                    "firstname": {
                        "type": "string",
                        "maxLength": 30,
                        "readOnly": true,
                        "description": "The employee’s first name.",
                        "x-example": "Jane"
                    },
                    "lastname": {
                        "type": "string",
                        "maxLength": 30,
                        "readOnly": true,
                        "description": "The employee’s last name.",
                        "x-example": "Smith"
                    },
                    "cancel": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "True once cancelled.",
                        "x-example": false
                    }
                }
            },
            "RefCheckaccounts": {
                "type": "object",
                "description": "**Read-only.** Bank accounts carry `accountnumber`, positive-pay SFTP credentials and private keys. Those are never returned, and the account is not writable through the API - changing where money moves is not an integration operation.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 3
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 30,
                        "readOnly": true,
                        "description": "Account name.",
                        "x-example": "Operating"
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "readOnly": true,
                        "description": "Currency code.",
                        "x-example": "USD"
                    },
                    "ap": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "Available for payables.",
                        "x-example": true
                    },
                    "ar": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "Available for receivables.",
                        "x-example": true
                    },
                    "inactive": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "Not in use.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "True once cancelled.",
                        "x-example": false
                    }
                }
            },
            "RefCcaccounts": {
                "type": "object",
                "description": "Merchant accounts used to take card payments. The processor behind each one is a static lookup and is not exposed.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Account name.",
                        "x-example": "Main merchant"
                    },
                    "ccprocessorid": {
                        "type": "integer",
                        "description": "Processor. See `ccprocessors` - read-only, it is a static table.",
                        "x-example": 1
                    },
                    "ccprocessor": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Processor name instead of the id.",
                        "x-example": "PaidYET"
                    },
                    "checkacctid": {
                        "type": "integer",
                        "description": "Bank account deposits land in.",
                        "x-example": 3
                    },
                    "checkacct": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Bank account name (`checkacct.name`) instead of the id.",
                        "x-example": "Operating"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this credit card accounts. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification. Drives `modifiedsince`."
                    }
                }
            },
            "RefCostcodes": {
                "type": "object",
                "description": "Cost codes for job and project costing.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 4
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code.",
                        "x-example": "LAB"
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Label.",
                        "x-example": "Labour"
                    },
                    "blocksales": {
                        "type": "boolean",
                        "description": "Blocked from use on sales.",
                        "x-example": false
                    },
                    "inactive": {
                        "type": "boolean",
                        "description": "Not in use. Distinct from `cancel`.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this cost codes. Scoped to your company."
                    }
                }
            },
            "RefGlcategories": {
                "type": "object",
                "description": "Categories used to group GL activity for reporting.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The code.",
                        "x-example": "OVH"
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Label.",
                        "x-example": "Overhead"
                    },
                    "glcategorytypeid": {
                        "type": "integer",
                        "description": "Category type. See `glcategorytypes`.",
                        "x-example": 1
                    },
                    "glcategorytype": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Category type description instead of the id.",
                        "x-example": "Operating"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this gl categories. Scoped to your company."
                    }
                }
            },
            "RefGlcostcenters": {
                "type": "object",
                "description": "GL cost centers. Note the table has only a description, no separate code.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Label, and the only human key this table has.",
                        "x-example": "Plant 1"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this cost centers. Scoped to your company."
                    }
                }
            },
            "RefDepartments": {
                "type": "object",
                "description": "Departments, used for payroll expense allocation. Each carries the GL accounts wages and taxes post to.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "The code.",
                        "x-example": "SHIP"
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Label.",
                        "x-example": "Shipping"
                    },
                    "glwageexpenseid": {
                        "type": "integer",
                        "description": "Wage expense account. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead.",
                        "x-example": 0,
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this departments. Scoped to your company."
                    }
                }
            },
            "RefTaxclasses": {
                "type": "object",
                "description": "Tax classes applied to items. The `avatax*` columns mirror an AvaTax tax code and are only meaningful on installs using it.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 2
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Class name.",
                        "x-example": "Taxable goods"
                    },
                    "exempt": {
                        "type": "boolean",
                        "description": "Items in this class are exempt.",
                        "x-example": false
                    },
                    "avataxtaxcode": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Matching AvaTax tax code.",
                        "x-example": ""
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this tax classes. Scoped to your company."
                    }
                }
            },
            "RefItemcomparisongroups": {
                "type": "object",
                "description": "Groups used to compare items against each other in the storefront.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Group name.",
                        "x-example": "Drill bits"
                    },
                    "hidden": {
                        "type": "boolean",
                        "description": "Hidden from display.",
                        "x-example": false
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this item comparison groups. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification. Drives `modifiedsince`."
                    }
                }
            },
            "RefSurveys": {
                "type": "object",
                "description": "Customer surveys, referenced from email templates and areas. The stored row has an `active` column meaning \"currently collecting responses\". It is **not exposed**: a resource carrying both `active` and `cancel` with different meanings is exactly the ambiguity D23 removes. Ask if you need it and it comes back under a name that cannot be misread.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Survey name.",
                        "x-example": "Post-service"
                    },
                    "surveytype": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Who the survey targets: customer or employee.",
                        "x-example": "email"
                    },
                    "url": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Where the survey lives.",
                        "x-example": ""
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this surveys. Scoped to your company."
                    }
                }
            },
            "RefQuotecomments": {
                "type": "object",
                "description": "Standard comment blocks attached to customers for quoting. **This is `quotecomment`, not `estquotequotenotes`** - the UI joins `quotecomment.id = customer.quotecommentid` (`arcustcsvlist.php:118`). The Estimating table of a similar name is a different thing and is not exposed.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 3
                    },
                    "comments": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The comment text.",
                        "x-example": "Quote Comment"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key for this quote comments. Scoped to your company."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last modification. Drives `modifiedsince`."
                    }
                }
            },
            "RefCcprocessors": {
                "type": "object",
                "description": "Payment processors NolaPro can talk to. **A static table** - `dbupdate.php` rebuilds it on every update, so it is read-only and your own rows would not survive. Referenced by `ccaccounts.ccprocessorid`.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Processor id.",
                        "x-example": 1
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "readOnly": true,
                        "description": "Processor name.",
                        "x-example": "PaidYET"
                    },
                    "modulename": {
                        "type": "string",
                        "maxLength": 100,
                        "readOnly": true,
                        "description": "Internal module handling this processor.",
                        "x-example": ""
                    }
                }
            },
            "RefGlaccounttypes": {
                "type": "object",
                "description": "The account types behind `glaccounts.accounttypeid` - asset, liability, income and so on. Fixed by double-entry accounting rather than by configuration, so read-only.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Name of the account type (asset, liability, income, ...)."
                    }
                }
            },
            "RefGlcategorytypes": {
                "type": "object",
                "description": "Types used to classify GL categories. Referenced by `glcategories.glcategorytypeid`.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id.",
                        "x-example": 1
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Label, and the only human key this table has.",
                        "x-example": "Operating"
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "True once cancelled.",
                        "x-example": false
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojects": {
                "type": "object",
                "description": "Projects. `projectcode` is the display id (TPM-001).",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Project name."
                    },
                    "projectcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Short code identifying the project."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Teamproject_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "notstarted",
                            "inprogress",
                            "onhold",
                            "completed",
                            "cancelled"
                        ]
                    },
                    "priority": {
                        "type": "string",
                        "description": "Priority. Labels are `Teamproject_model::$priorities`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "low",
                            "normal",
                            "high",
                            "critical"
                        ]
                    },
                    "manageruserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `manageruser`."
                    },
                    "manageruser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the project manager. Send this or `manageruserid`, not both unless they agree."
                    },
                    "teamprojectcategoryid": {
                        "type": "integer",
                        "description": "Reference to `teamprojectcategories`, by id. Write either this or `teamprojectcategory`."
                    },
                    "teamprojectcategory": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojectcategory, instead of the id."
                    },
                    "color": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Display colour, hex."
                    },
                    "startdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project starts."
                    },
                    "targetenddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project is planned to finish."
                    },
                    "actualenddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project actually finished."
                    },
                    "budgethours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "budgetamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "percentcomplete": {
                        "type": "integer",
                        "description": "Progress, 0 to 100."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttasks": {
                "type": "object",
                "description": "Tasks. `parenttaskid` nests one level only; `taskseq` is the per-project number.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "teamprojectmilestoneid": {
                        "type": "integer",
                        "description": "Teamprojectmilestoneid. Id only - `teamprojectmilestone` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "parenttaskid": {
                        "type": "integer",
                        "description": "Parenttaskid. Id only.",
                        "x-idonly": true
                    },
                    "taskseq": {
                        "type": "integer",
                        "description": "Per-project sequence number. Assigned automatically (MAX+1 for the project) when omitted on create; send one only to control it explicitly."
                    },
                    "displayid": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The task id shown everywhere in TPM (TPM-001-15). Derived by the model from the project code and taskseq on every save. Read-only - a sent value would be silently overwritten, so it is refused instead.",
                        "readOnly": true
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Task title."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "teamprojectstatusid": {
                        "type": "integer",
                        "description": "Reference to `teamprojectstatuses`, by id. Write either this or `teamprojectstatus`."
                    },
                    "teamprojectstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojectstatus, instead of the id."
                    },
                    "priority": {
                        "type": "string",
                        "description": "Priority. Labels are `Teamprojecttask_model::$priorities`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "low",
                            "normal",
                            "high",
                            "critical"
                        ]
                    },
                    "startdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date work on the task starts."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "estimatedhours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "percentcomplete": {
                        "type": "integer",
                        "description": "Progress, 0 to 100."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "requiresapproval": {
                        "type": "boolean",
                        "description": "True routes task completion through an approval step."
                    },
                    "approvaluserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `approvaluser`."
                    },
                    "approvaluser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the approver. Send this or `approvaluserid`, not both unless they agree."
                    },
                    "approvalstatus": {
                        "type": "string",
                        "enum": [
                            "notrequested",
                            "pending",
                            "approved",
                            "rejected"
                        ],
                        "description": "Approval workflow state. Labels are `Teamprojecttask_model::$approvalstatuses`; stored as an int and never exposed or accepted as one (D35). Only meaningful when `requiresapproval` is true."
                    },
                    "approvaldate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the completed task was approved."
                    },
                    "approvalcomment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Approvalcomment. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectmilestones": {
                "type": "object",
                "description": "Milestones within a project.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Milestone name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Teamprojectmilestone_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "pending",
                            "inprogress",
                            "completed",
                            "missed"
                        ]
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectstatuses": {
                "type": "object",
                "description": "Custom task statuses. `iscomplete` marks the ones that close a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Status name shown on tasks and board columns."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "color": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Display colour, hex."
                    },
                    "iscomplete": {
                        "type": "boolean",
                        "description": "True counts tasks in this status as complete."
                    },
                    "isboardvisible": {
                        "type": "boolean",
                        "description": "True shows the status as a column on the project board."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectcategories": {
                "type": "object",
                "description": "Optional grouping for projects.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Category name shown on projects."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttags": {
                "type": "object",
                "description": "Tags, shared company-wide across all projects.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Tag text shown on tasks."
                    },
                    "color": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Display colour, hex."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectcomments": {
                "type": "object",
                "description": "Discussion on a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "parentcommentid": {
                        "type": "integer",
                        "description": "Parentcommentid. Id only.",
                        "x-idonly": true
                    },
                    "comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Comment. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectchecklists": {
                "type": "object",
                "description": "Checklist sub-items on a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Checklist item text."
                    },
                    "iscomplete": {
                        "type": "boolean",
                        "description": "True once the checklist item is checked off."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "parentchecklistid": {
                        "type": "integer",
                        "description": "Parentchecklistid. Id only.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttimelogs": {
                "type": "object",
                "description": "Time entries. `teamprojecttaskid` 0 means project-level. `status` 1 is a running timer.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the person the time belongs to. Send this or `genuserid`, not both unless they agree."
                    },
                    "employeeid": {
                        "type": "integer",
                        "description": "Employeeid. Id only - `premployee` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "logdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the time is logged against."
                    },
                    "hours": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "billable": {
                        "type": "boolean",
                        "description": "True when the logged time is billable."
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "billrate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "costrate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "arserviceorder_timeid": {
                        "type": "integer",
                        "description": "Arserviceorder timeid. Id only.",
                        "x-idonly": true
                    },
                    "status": {
                        "type": "boolean",
                        "description": "1 while the timer is running; 0 once the entry is stopped and logged."
                    },
                    "startdatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the timer started."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttemplates": {
                "type": "object",
                "description": "Saved project templates.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Template name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttemplateitems": {
                "type": "object",
                "description": "Milestones and tasks inside a template.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttemplateid": {
                        "type": "integer",
                        "description": "Reference to `teamprojecttemplates`, by id. Write either this or `teamprojecttemplate`."
                    },
                    "teamprojecttemplate": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojecttemplate, instead of the id."
                    },
                    "parentitemid": {
                        "type": "integer",
                        "description": "Parentitemid. Id only."
                    },
                    "parentitem": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `parentitemid`, not both unless they agree."
                    },
                    "itemtype": {
                        "type": "integer",
                        "description": "What the template item creates: 0 = milestone, 1 = task."
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Title given to the created task or milestone."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "priority": {
                        "type": "integer",
                        "description": "Priority of the created task: 0 = low, 1 = normal, 2 = high, 3 = critical."
                    },
                    "estimatedhours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "offsetdays": {
                        "type": "integer",
                        "description": "Days after the project start that the item begins."
                    },
                    "durationdays": {
                        "type": "integer",
                        "description": "How many days the item runs; sets its due date."
                    },
                    "assignrole": {
                        "type": "boolean",
                        "description": "True assigns the created task by project role rather than to a specific user."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectrecurringtasks": {
                "type": "object",
                "description": "Recurring task definitions, generated by the processqueue cron.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "teamprojectmilestoneid": {
                        "type": "integer",
                        "description": "Teamprojectmilestoneid. Id only - `teamprojectmilestone` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Title given to each generated task."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "teamprojectstatusid": {
                        "type": "integer",
                        "description": "Reference to `teamprojectstatuses`, by id. Write either this or `teamprojectstatus`."
                    },
                    "teamprojectstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojectstatus, instead of the id."
                    },
                    "priority": {
                        "type": "integer",
                        "description": "Priority of generated tasks: 0 = low, 1 = normal, 2 = high, 3 = critical."
                    },
                    "estimatedhours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "assignuserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `assignuser`."
                    },
                    "assignuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the default assignee. Send this or `assignuserid`, not both unless they agree."
                    },
                    "frequency": {
                        "type": "integer",
                        "description": "How often a task is generated: 0 = daily, 1 = weekly, 2 = monthly, 3 = custom (every `intervaldays` days)."
                    },
                    "intervaldays": {
                        "type": "integer",
                        "description": "Days between generated tasks when `frequency` is custom."
                    },
                    "dayofweek": {
                        "type": "integer",
                        "description": "Day of the week a weekly recurrence generates on (0 = Sunday)."
                    },
                    "dayofmonth": {
                        "type": "integer",
                        "description": "Day of the month a monthly recurrence generates on."
                    },
                    "nextrundate": {
                        "type": "string",
                        "format": "date",
                        "description": "Next date a task will be generated."
                    },
                    "enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the recurrence stops; empty runs indefinitely."
                    },
                    "lastrundate": {
                        "type": "string",
                        "format": "date",
                        "description": "When the recurrence last generated a task. Maintained by the generator, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "enabled": {
                        "type": "boolean",
                        "description": "True while the recurrence is active."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectmembers": {
                "type": "object",
                "description": "Team membership. `role` 0=Manager, 1=Member, 2=Viewer.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the member. Send this or `genuserid`, not both unless they agree."
                    },
                    "role": {
                        "type": "string",
                        "description": "Role. Labels are `Teamprojectuser_model::$roles`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "manager",
                            "member",
                            "viewer"
                        ]
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttaskassignees": {
                "type": "object",
                "description": "Who a task is assigned to. Many-to-many.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the assignee. Send this or `genuserid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttaskwatchers": {
                "type": "object",
                "description": "Who gets notified about a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the watcher. Send this or `genuserid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttaskdependencies": {
                "type": "object",
                "description": "Finish-to-start links. Advisory only - nothing is blocked from starting.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "dependsontaskid": {
                        "type": "integer",
                        "description": "Dependsontaskid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttasktags": {
                "type": "object",
                "description": "Links a tag to a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "teamprojecttagid": {
                        "type": "integer",
                        "description": "Reference to `teamprojecttags`, by id. Write either this or `teamprojecttag`."
                    },
                    "teamprojecttag": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojecttag, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttaglinks": {
                "type": "object",
                "description": "Links a tag to a project.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "teamprojecttagid": {
                        "type": "integer",
                        "description": "Reference to `teamprojecttags`, by id. Write either this or `teamprojecttag`."
                    },
                    "teamprojecttag": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojecttag, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectreminders": {
                "type": "object",
                "description": "Scheduled reminders on a task.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the person reminded. Send this or `genuserid`, not both unless they agree."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "reminderdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the reminder fires."
                    },
                    "note": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Reminder text."
                    },
                    "status": {
                        "type": "boolean",
                        "description": "0 while the reminder is pending; 1 once it is done."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectautomations": {
                "type": "object",
                "description": "Rules that act on project events.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Automation name."
                    },
                    "triggertype": {
                        "type": "integer",
                        "description": "What fires the automation: 0 = status changed, 1 = task assigned, 2 = due date reached, 3 = due date approaching, 4 = task created, 5 = milestone completed, 6 = priority changed."
                    },
                    "triggervalue": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Triggervalue. Stored as `text`, no practical length limit."
                    },
                    "actiontype": {
                        "type": "integer",
                        "description": "What the automation does: 0 = change status, 1 = reassign task, 2 = set priority, 3 = add tag, 4 = send notification, 5 = add comment."
                    },
                    "actionvalue": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Actionvalue. Stored as `text`, no practical length limit."
                    },
                    "enabled": {
                        "type": "boolean",
                        "description": "True while the automation is active."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectviews": {
                "type": "object",
                "description": "Saved board and list views.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the view owner. Send this or `genuserid`, not both unless they agree."
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Name of the saved view."
                    },
                    "filters": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Filters. Stored as `text`, no practical length limit."
                    },
                    "sortconfig": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Sortconfig. Stored as `text`, no practical length limit."
                    },
                    "columns": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Columns. Stored as `text`, no practical length limit."
                    },
                    "isshared": {
                        "type": "boolean",
                        "description": "True shares the view with the whole team."
                    },
                    "isglobal": {
                        "type": "boolean",
                        "description": "True applies the view across all projects rather than one."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectsettings": {
                "type": "object",
                "description": "Module settings, key/value.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "settingkey": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the setting (unique per project)."
                    },
                    "settingvalue": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Value stored for the setting."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojectactivity": {
                "type": "object",
                "description": "**Read-only.** Auto-logged change history. Written by the application, never by a caller.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "action": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The code this resource is keyed by. Matching is case insensitive."
                    },
                    "source": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Where the change came from (screen or process that made it)."
                    },
                    "fieldname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Field that changed."
                    },
                    "oldvalue": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Value before the change."
                    },
                    "newvalue": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Value after the change."
                    },
                    "detail": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Detail. Stored as `text`, no practical length limit."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    }
                }
            },
            "RefVendors": {
                "type": "object",
                "description": "The companies you buy from. Bank details are never returned - see Conventions.",
                "properties": {
                    "name": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Last name, for an individual vendor. The display name uses `companyname` when that is set, otherwise the personal name fields."
                    },
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "orderfromname": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Contact name on the Order From address block - where purchase orders go when ordering differs from the payment address."
                    },
                    "paytermsid": {
                        "type": "integer",
                        "description": "Paytermsid. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead.",
                        "x-idonly": true
                    },
                    "paynone": {
                        "type": "integer",
                        "description": "1 puts the vendor on payment hold: payment runs set to skip held vendors exclude their bills, and bill lists mark the vendor with *."
                    },
                    "defaultglacctid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `defaultglacct`."
                    },
                    "defaultglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "defaultbilldescription": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Description pre-filled on new bills entered for this vendor."
                    },
                    "customeraccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Your account number with this vendor, printed on payments."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "companyname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Company name. When set it is the vendor’s display name; otherwise the salutation/first/middle/name/suffix fields are used."
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "mailstop": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Mail stop line printed with the payment address."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the payment address."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the payment address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the payment address."
                    },
                    "phone1": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Primary phone."
                    },
                    "phone1comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone1 reaches (Office, Mobile, ...)."
                    },
                    "phone2": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone2comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone2 reaches (Office, Mobile, ...)."
                    },
                    "phone3": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone3comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone3 reaches (Office, Mobile, ...)."
                    },
                    "phone4": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone4comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone4 reaches (Office, Mobile, ...)."
                    },
                    "email1": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Primary email address."
                    },
                    "email1comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what email1 is for."
                    },
                    "email2": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Secondary email."
                    },
                    "email2comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what email2 is for."
                    },
                    "website": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Vendor’s website URL."
                    },
                    "orderfrom_companyname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Company name on the Order From address, when purchase orders go to a different address than payments."
                    },
                    "orderfrom_address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address line 1 of the Order From address."
                    },
                    "orderfrom_address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address line 2 of the Order From address."
                    },
                    "orderfrom_mailstop": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Mail stop line of the Order From address."
                    },
                    "orderfrom_city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the Order From address."
                    },
                    "orderfrom_state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the Order From address."
                    },
                    "orderfrom_zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "ZIP/postal code of the Order From address."
                    },
                    "orderfrom_country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the Order From address."
                    },
                    "image": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "Filename of the picture uploaded on the vendor screen. Managed by the file upload, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "default_cost_per_hour": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,6)`.",
                        "x-decimals": 6
                    },
                    "vendor_code": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Vendor number, shown as Vendor Code on the vendor screens. Auto-assigned from the company’s next-vendor-code counter when left blank."
                    },
                    "vendor_lead_time": {
                        "type": "integer",
                        "description": "Lead time in days. New purchase orders default their due date this many days out."
                    },
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Default carrier service (ship method) for this vendor’s purchase orders."
                    },
                    "carrierservice": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrierservice, instead of the id."
                    },
                    "noreturns": {
                        "type": "integer",
                        "description": "1 blocks RMA returns to this vendor."
                    },
                    "percent_commission": {
                        "type": "string",
                        "description": "Numeric string, 4 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 4,
                        "x-number": true
                    },
                    "flat_commission": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "parent_vendorid": {
                        "type": "integer",
                        "description": "Parent vendor, when this record is a location or division of a larger vendor."
                    },
                    "parent_vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Vendor code of the parent vendor. Send this or `parent_vendorid`, not both unless they agree."
                    },
                    "taxgroupid": {
                        "type": "integer",
                        "description": "Tax group applied to this vendor’s purchases."
                    },
                    "taxgroup": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced taxgroup, instead of the id."
                    },
                    "vendorcode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Older short vendor code, appended to the display name in parentheses."
                    },
                    "salutation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Salutation for an individual vendor (Mr., Ms., ...)."
                    },
                    "first_name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "First name, for an individual vendor."
                    },
                    "middle_name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Middle name, for an individual vendor."
                    },
                    "name_suffix": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Name suffix for an individual vendor (Jr., III, ...)."
                    },
                    "vendortypeid": {
                        "type": "integer",
                        "description": "Reference to `vendortypes`, by id. Write either this or `vendortype`."
                    },
                    "vendortype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced vendortype, instead of the id."
                    },
                    "default_retainer": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(6,3)`.",
                        "x-decimals": 3
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the vendor bills in. Bills and purchase orders for the vendor default to it."
                    },
                    "gets1099": {
                        "type": "integer",
                        "description": "1 when the vendor receives a 1099 at year end."
                    },
                    "basevendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `basevendor`."
                    },
                    "basevendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Vendor code of the base vendor. Send this or `basevendorid`, not both unless they agree."
                    },
                    "buyeruserid": {
                        "type": "integer",
                        "description": "Buyeruserid. Id only."
                    },
                    "buyeruser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the buyer. Send this or `buyeruserid`, not both unless they agree."
                    },
                    "default_checkacctid": {
                        "type": "integer",
                        "description": "Checking account payments to this vendor default to."
                    },
                    "default_checkacct": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Name of the default bank account. Send this or `default_checkacctid`, not both unless they agree."
                    },
                    "default_paymethod": {
                        "type": "integer",
                        "description": "Default payment method for bills: 1 = cash, 2 = check, 3 = credit card, 4 = ACH/EFT; 0 when none is set."
                    },
                    "lead": {
                        "type": "boolean",
                        "description": "True when the record is a prospective vendor entered as a lead (Leads feature) rather than an active vendor."
                    },
                    "orderfrom_email": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email address purchase orders are sent to."
                    },
                    "orderfrom_fax": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Fax number for sending purchase orders."
                    },
                    "orderfrom_phone": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Phone number of the ordering contact."
                    },
                    "paytoname": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Pay To name printed on checks, when different from the vendor name."
                    },
                    "taskstatusid": {
                        "type": "integer",
                        "description": "Reference to `taskstatuses`, by id. Write either this or `taskstatus`."
                    },
                    "taskstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Task status name. Send this or `taskstatusid`, not both unless they agree."
                    },
                    "timezoneid": {
                        "type": "integer",
                        "description": "Reference to `timezones`, by id. Write either this or `timezone`."
                    },
                    "timezone": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "IANA time zone name. Send this or `timezoneid`, not both unless they agree."
                    },
                    "insuranceemail": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Email address of the vendor’s insurance contact, used for certificate-of-insurance tracking."
                    },
                    "insuranceemailcomment": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Label describing the insurance email contact."
                    },
                    "insurancephone": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Phone number of the vendor’s insurance contact."
                    },
                    "insurancephonecomment": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Label describing the insurance phone contact."
                    },
                    "paytoemail": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email address payment remittances are sent to."
                    },
                    "excludefrompaymentreport": {
                        "type": "boolean",
                        "description": "True leaves the vendor off payment reports."
                    },
                    "insurancefax": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Fax number of the vendor’s insurance contact."
                    },
                    "insurancefaxcomment": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Label describing the insurance fax contact."
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "displayname": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "readOnly": true
                    },
                    "displaynamenocode": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefVendortypes": {
                "type": "object",
                "description": "Vendor classification.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the vendor type."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefWorktypes": {
                "type": "object",
                "description": "Work types used on projects, tasks and time logs.",
                "properties": {
                    "id_worktype": {
                        "type": "integer",
                        "description": "Primary key of the work type (this table is keyed `id_worktype`, not `id`).",
                        "readOnly": true
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the production work type."
                    },
                    "purpose": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "What the work type is used for, shown on the work type list."
                    },
                    "createdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the change happened, not when we sent it. A retry two hours later still carries the original time."
                    },
                    "id_user_create": {
                        "type": "integer",
                        "description": "User who created the record.",
                        "readOnly": true
                    },
                    "orderflag": {
                        "type": "integer",
                        "description": "Display order of the work type in pickers."
                    },
                    "lastrevisedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was last revised.",
                        "readOnly": true
                    },
                    "id_user_revise": {
                        "type": "integer",
                        "description": "User who last revised the record.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCarriers": {
                "type": "object",
                "description": "Shipping carriers. The carrier account credentials (`accesskey`, `sitelogin`, `sitepassword`) are never returned and never accepted - a carrier login is a credential like any other.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "customernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Your account number with the carrier."
                    },
                    "trackingurlbase": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Base URL used to build tracking links for this carrier."
                    },
                    "trackingurlvarname": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Query parameter name the tracking number is appended as when building tracking links."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Carrier name shown on documents and pickers."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "carrier_upcharge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(5,2)`.",
                        "x-decimals": 2
                    },
                    "carrier_upcharge_flat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "maxboxweight": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "shipheight": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shiplength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shipwidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "usenegotiatedrates": {
                        "type": "integer",
                        "description": "1 rates shipments with your negotiated carrier rates instead of published rates."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCarrierservices": {
                "type": "object",
                "description": "Service levels offered by a carrier.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "carrierid": {
                        "type": "integer",
                        "description": "Reference to `carriers`, by id. Write either this or `carrier`."
                    },
                    "carrier": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrier, instead of the id."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the shipping method shown on documents and pickers."
                    },
                    "abbreviation": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Short abbreviation of the shipping method."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "not_on_b2b": {
                        "type": "integer",
                        "description": "1 hides the shipping method from the B2B portal."
                    },
                    "onquote": {
                        "type": "integer",
                        "description": "1 hides the shipping method from quote entry (the screen option is named Do Not Show On Quote Entry)."
                    },
                    "box1_charge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "box_addl": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "require_shippernum": {
                        "type": "integer",
                        "description": "1 requires the customer’s shipper (carrier account) number when this method is chosen."
                    },
                    "showvalue": {
                        "type": "integer",
                        "description": "1 prints the order value on the order ticket for this method."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Carrier’s own service code, used when rating and labeling through the carrier API."
                    },
                    "methodmarkupflat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "saturdaydelivery": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Y when the service delivers on Saturday."
                    },
                    "allowonpointofsaleorders": {
                        "type": "boolean",
                        "description": "True offers the shipping method on Point of Sale orders."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefTeamprojecttasksCreate": {
                "type": "object",
                "description": "A task created inside its parent. `teamprojectid` and `teamprojectmilestoneid` are **not** sent - the nesting says which project and milestone it belongs to, and the ids do not exist yet when you send the request.",
                "properties": {
                    "parenttaskid": {
                        "type": "integer",
                        "description": "Parenttaskid. Id only.",
                        "x-idonly": true
                    },
                    "taskseq": {
                        "type": "integer",
                        "description": "Per-project sequence number. Assigned automatically (MAX+1 for the project) when omitted on create; send one only to control it explicitly."
                    },
                    "displayid": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The task id shown everywhere in TPM (TPM-001-15). Derived by the model from the project code and taskseq on every save. Read-only - a sent value would be silently overwritten, so it is refused instead.",
                        "readOnly": true
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Task title."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "teamprojectstatusid": {
                        "type": "integer",
                        "description": "Reference to `teamprojectstatuses`, by id. Write either this or `teamprojectstatus`."
                    },
                    "teamprojectstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojectstatus, instead of the id."
                    },
                    "priority": {
                        "type": "string",
                        "description": "Priority. Labels are `Teamprojecttask_model::$priorities`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "low",
                            "normal",
                            "high",
                            "critical"
                        ]
                    },
                    "startdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date work on the task starts."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "estimatedhours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "percentcomplete": {
                        "type": "integer",
                        "description": "Progress, 0 to 100."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "requiresapproval": {
                        "type": "boolean",
                        "description": "True routes task completion through an approval step."
                    },
                    "approvaluserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `approvaluser`."
                    },
                    "approvaluser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the approver. Send this or `approvaluserid`, not both unless they agree."
                    },
                    "approvalstatus": {
                        "type": "string",
                        "enum": [
                            "notrequested",
                            "pending",
                            "approved",
                            "rejected"
                        ],
                        "description": "Approval workflow state. Labels are `Teamprojecttask_model::$approvalstatuses`; stored as an int and never exposed or accepted as one (D35). Only meaningful when `requiresapproval` is true."
                    },
                    "approvaldate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the completed task was approved."
                    },
                    "approvalcomment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Approvalcomment. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "checklist": {
                        "type": "array",
                        "description": "Checklist items on this task, in order.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojectchecklistsCreate"
                        }
                    },
                    "assignees": {
                        "type": "array",
                        "description": "Who the task is assigned to.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttaskassigneesCreate"
                        }
                    },
                    "watchers": {
                        "type": "array",
                        "description": "Who gets notified about it.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttaskwatchersCreate"
                        }
                    },
                    "tags": {
                        "type": "array",
                        "description": "Tags to attach. The tag itself must already exist.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttasktagsCreate"
                        }
                    },
                    "comments": {
                        "type": "array",
                        "description": "An opening comment or two.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojectcommentsCreate"
                        }
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    },
                    "teamprojectmilestoneid": {
                        "type": "integer",
                        "description": "Teamprojectmilestoneid. Id only - `teamprojectmilestone` is read-only or has no code key.",
                        "x-idonly": true
                    }
                },
                "x-children": [
                    "checklist",
                    "assignees",
                    "watchers",
                    "tags",
                    "comments"
                ]
            },
            "RefTeamprojectmilestonesCreate": {
                "type": "object",
                "description": "A milestone created inside its project. `teamprojectid` is not sent - the nesting says which project it belongs to.",
                "x-children": [
                    "tasks"
                ],
                "properties": {
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Milestone name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Teamprojectmilestone_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "pending",
                            "inprogress",
                            "completed",
                            "missed"
                        ]
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "tasks": {
                        "type": "array",
                        "description": "Tasks created under this milestone, in order. Each is attached to the milestone once it has an id.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttasksCreate"
                        }
                    },
                    "teamprojectid": {
                        "type": "integer",
                        "description": "Reference to `teamprojects`, by id. Write either this or `teamproject`."
                    },
                    "teamproject": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced teamproject, instead of the id."
                    }
                }
            },
            "RefTeamprojectsCreate": {
                "type": "object",
                "description": "A project, optionally with its milestones and tasks in the same request. The project is created first, then its children are attached to the new id - all inside one transaction, so a bad task means no project either.",
                "x-children": [
                    "milestones",
                    "tasks"
                ],
                "properties": {
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Project name."
                    },
                    "projectcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Short code identifying the project."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Teamproject_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "notstarted",
                            "inprogress",
                            "onhold",
                            "completed",
                            "cancelled"
                        ]
                    },
                    "priority": {
                        "type": "string",
                        "description": "Priority. Labels are `Teamproject_model::$priorities`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "low",
                            "normal",
                            "high",
                            "critical"
                        ]
                    },
                    "manageruserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `manageruser`."
                    },
                    "manageruser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the project manager. Send this or `manageruserid`, not both unless they agree."
                    },
                    "teamprojectcategoryid": {
                        "type": "integer",
                        "description": "Reference to `teamprojectcategories`, by id. Write either this or `teamprojectcategory`."
                    },
                    "teamprojectcategory": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojectcategory, instead of the id."
                    },
                    "color": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Display colour, hex."
                    },
                    "startdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project starts."
                    },
                    "targetenddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project is planned to finish."
                    },
                    "actualenddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the project actually finished."
                    },
                    "budgethours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "budgetamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "percentcomplete": {
                        "type": "integer",
                        "description": "Progress, 0 to 100."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "milestones": {
                        "type": "array",
                        "description": "Milestones created under this project, in order. Each may carry its own `tasks`.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojectmilestonesCreate"
                        }
                    },
                    "tasks": {
                        "type": "array",
                        "description": "Tasks created directly on the project, with no milestone. Use the `tasks` inside a milestone for tasks that belong to one.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttasksCreate"
                        }
                    }
                }
            },
            "RefTeamprojectchecklistsCreate": {
                "type": "object",
                "description": "Created inside its task. `teamprojecttaskid` is not sent - the nesting says which task.",
                "properties": {
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Checklist item text."
                    },
                    "iscomplete": {
                        "type": "boolean",
                        "description": "True once the checklist item is checked off."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "parentchecklistid": {
                        "type": "integer",
                        "description": "Parentchecklistid. Id only.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    }
                }
            },
            "RefTeamprojectcommentsCreate": {
                "type": "object",
                "description": "Created inside its task. `teamprojecttaskid` is not sent - the nesting says which task.",
                "properties": {
                    "parentcommentid": {
                        "type": "integer",
                        "description": "Parentcommentid. Id only.",
                        "x-idonly": true
                    },
                    "comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Comment. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    }
                }
            },
            "RefTeamprojecttaskassigneesCreate": {
                "type": "object",
                "description": "Created inside its task. `teamprojecttaskid` is not sent - the nesting says which task.",
                "properties": {
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the assignee. Send this or `genuserid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    }
                }
            },
            "RefTeamprojecttaskwatchersCreate": {
                "type": "object",
                "description": "Created inside its task. `teamprojecttaskid` is not sent - the nesting says which task.",
                "properties": {
                    "genuserid": {
                        "type": "integer",
                        "description": "Genuserid. Id only - `genuser` is read-only or has no code key."
                    },
                    "genuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Login name of the watcher. Send this or `genuserid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    }
                }
            },
            "RefTeamprojecttasktagsCreate": {
                "type": "object",
                "description": "Created inside its task. `teamprojecttaskid` is not sent - the nesting says which task.",
                "properties": {
                    "teamprojecttagid": {
                        "type": "integer",
                        "description": "Reference to `teamprojecttags`, by id. Write either this or `teamprojecttag`."
                    },
                    "teamprojecttag": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojecttag, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttaskid": {
                        "type": "integer",
                        "description": "Teamprojecttaskid. Id only - `teamprojecttask` is read-only or has no code key.",
                        "x-idonly": true
                    }
                }
            },
            "RefTeamprojecttemplateitemsCreate": {
                "type": "object",
                "description": "A milestone or task inside a template. `teamprojecttemplateid` is not sent.",
                "properties": {
                    "teamprojecttemplate": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced teamprojecttemplate, instead of the id."
                    },
                    "parentitemid": {
                        "type": "integer",
                        "description": "Parentitemid. Id only.",
                        "x-idonly": true
                    },
                    "itemtype": {
                        "type": "integer",
                        "description": "What the template item creates: 0 = milestone, 1 = task."
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Title given to the created task or milestone."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "priority": {
                        "type": "integer",
                        "description": "Priority of the created task: 0 = low, 1 = normal, 2 = high, 3 = critical."
                    },
                    "estimatedhours": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "offsetdays": {
                        "type": "integer",
                        "description": "Days after the project start that the item begins."
                    },
                    "durationdays": {
                        "type": "integer",
                        "description": "How many days the item runs; sets its due date."
                    },
                    "assignrole": {
                        "type": "boolean",
                        "description": "True assigns the created task by project role rather than to a specific user."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "teamprojecttemplateid": {
                        "type": "integer",
                        "description": "Reference to `teamprojecttemplates`, by id. Write either this or `teamprojecttemplate`."
                    },
                    "parentitem": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `parentitemid`, not both unless they agree."
                    }
                }
            },
            "RefTeamprojecttemplatesCreate": {
                "type": "object",
                "description": "A template, optionally with all of its items in the same request.",
                "x-children": [
                    "items"
                ],
                "properties": {
                    "name": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Template name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "items": {
                        "type": "array",
                        "description": "The milestones and tasks that make up this template, in order.",
                        "items": {
                            "$ref": "#/components/schemas/RefTeamprojecttemplateitemsCreate"
                        }
                    }
                }
            },
            "RefCarrierservicesCreate": {
                "type": "object",
                "description": "A service level inside its carrier. `carrierid` is not sent.",
                "properties": {
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the shipping method shown on documents and pickers."
                    },
                    "abbreviation": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Short abbreviation of the shipping method."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "not_on_b2b": {
                        "type": "integer",
                        "description": "1 hides the shipping method from the B2B portal."
                    },
                    "onquote": {
                        "type": "integer",
                        "description": "1 hides the shipping method from quote entry (the screen option is named Do Not Show On Quote Entry)."
                    },
                    "box1_charge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "box_addl": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "require_shippernum": {
                        "type": "integer",
                        "description": "1 requires the customer’s shipper (carrier account) number when this method is chosen."
                    },
                    "showvalue": {
                        "type": "integer",
                        "description": "1 prints the order value on the order ticket for this method."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Carrier’s own service code, used when rating and labeling through the carrier API."
                    },
                    "methodmarkupflat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "saturdaydelivery": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Y when the service delivers on Saturday."
                    },
                    "allowonpointofsaleorders": {
                        "type": "boolean",
                        "description": "True offers the shipping method on Point of Sale orders."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "carrierid": {
                        "type": "integer",
                        "description": "Reference to `carriers`, by id. Write either this or `carrier`."
                    },
                    "carrier": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrier, instead of the id."
                    }
                }
            },
            "RefCarriersCreate": {
                "type": "object",
                "description": "A carrier, optionally with its service levels in the same request.",
                "x-children": [
                    "services"
                ],
                "properties": {
                    "customernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Your account number with the carrier."
                    },
                    "trackingurlbase": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Base URL used to build tracking links for this carrier."
                    },
                    "trackingurlvarname": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Query parameter name the tracking number is appended as when building tracking links."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Carrier name shown on documents and pickers."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "carrier_upcharge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(5,2)`.",
                        "x-decimals": 2
                    },
                    "carrier_upcharge_flat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "maxboxweight": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "shipheight": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shiplength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "shipwidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,2)`.",
                        "x-decimals": 2
                    },
                    "usenegotiatedrates": {
                        "type": "integer",
                        "description": "1 rates shipments with your negotiated carrier rates instead of published rates."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "services": {
                        "type": "array",
                        "description": "Service levels offered by this carrier.",
                        "items": {
                            "$ref": "#/components/schemas/RefCarrierservicesCreate"
                        }
                    }
                }
            },
            "RefShiptos": {
                "type": "object",
                "description": "Delivery addresses on a customer. An order or invoice ships to one of these.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "defaultshipvia": {
                        "type": "integer",
                        "description": "Default shipping method (carrier service) for orders shipping to this address."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "mailstop": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Mail stop line printed with the address."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the address."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the address."
                    },
                    "phone1": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Primary phone."
                    },
                    "phone1comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone1 reaches (Office, Mobile, ...)."
                    },
                    "phone2": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone2comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone2 reaches (Office, Mobile, ...)."
                    },
                    "phone3": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone3comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone3 reaches (Office, Mobile, ...)."
                    },
                    "phone4": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Additional phone number."
                    },
                    "phone4comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what phone4 reaches (Office, Mobile, ...)."
                    },
                    "email1": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Primary email address for this location."
                    },
                    "email2": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Secondary email."
                    },
                    "email1comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what email1 is for."
                    },
                    "email2comment": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Label describing what email2 is for."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "shipname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Ship To name printed on shipping documents."
                    },
                    "entry_firstname": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "First name of the receiving contact, printed as the ship-to attention line."
                    },
                    "entry_lastname": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Last name of the receiving contact, printed as the ship-to attention line."
                    },
                    "entry_country_id": {
                        "type": "integer",
                        "description": "Numeric country id in the osCommerce-style cart tables. Kept for shopping-cart integrations; the address itself uses `country`."
                    },
                    "entry_country": {
                        "type": "string",
                        "maxLength": 2,
                        "description": "The `countries_iso_code_2` of the referenced countries, instead of the id. Send this or `entry_country_id`, not both unless they agree."
                    },
                    "entry_zone_id": {
                        "type": "integer",
                        "description": "Numeric state/zone id in the osCommerce-style cart tables. Kept for shopping-cart integrations; the address itself uses `state`."
                    },
                    "entry_zone": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "The `zone_code` of the referenced zones, instead of the id. Send this or `entry_zone_id`, not both unless they agree."
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Reference to `taxexempts`, by id. Write either this or `taxexempt`."
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `taxexemptid`, not both unless they agree."
                    },
                    "salestaxnum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Sales tax registration number."
                    },
                    "weather_cf": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "C or F - the temperature unit for the weather shown for this location on scheduling screens."
                    },
                    "weather_zip": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "ZIP code used to look up the weather for this location."
                    },
                    "time_zone": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "UTC offset of the location, e.g. -05:00."
                    },
                    "is_default": {
                        "type": "integer",
                        "description": "1 when this is the customer’s default ship-to address."
                    },
                    "shipper_number": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Shipper Number - the customer’s carrier account that freight to this address is billed to, printed on invoices with the UPS account type."
                    },
                    "shipname2": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Second Ship To name line, printed under `shipname`."
                    },
                    "upstype": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "UPS Account Type that `shipper_number` refers to: SHP = shipper, REC = receiver, TP = third party, CB = consignee billed. Empty when not used."
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "blindship": {
                        "type": "boolean",
                        "description": "True when shipments to this address are blind shipments - shipping papers do not reveal the shipper."
                    },
                    "county": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "County of the address, used for county sales tax."
                    },
                    "countyid": {
                        "type": "string",
                        "maxLength": 25,
                        "description": "Tax-system county identifier used with `county` to pick the county tax; may be a dotted composite code."
                    },
                    "residential": {
                        "type": "integer",
                        "description": "1 when the address is residential. Affects carrier rating and tax address classification."
                    },
                    "timezoneid": {
                        "type": "integer",
                        "description": "Reference to `timezones`, by id. Write either this or `timezone`."
                    },
                    "timezone": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "The `name` of the referenced timezones, instead of the id. Send this or `timezoneid`, not both unless they agree."
                    },
                    "contactnameid": {
                        "type": "integer",
                        "description": "Contactnameid. Id only.",
                        "x-idonly": true
                    },
                    "salesinventorylocationid": {
                        "type": "integer",
                        "description": "Reference to `inventorylocations`, by id. Write either this or `salesinventorylocation`."
                    },
                    "salesinventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `salesinventorylocationid`, not both unless they agree."
                    },
                    "unincorporated": {
                        "type": "integer",
                        "description": "1 when the address is in an unincorporated area, so no city sales tax applies."
                    },
                    "recordtype": {
                        "type": "boolean",
                        "description": "True when the row is a bill-to address record. NolaPro stores bill-to and ship-to addresses in the same table."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefInvoices": {
                "type": "object",
                "description": "AR invoices. Lines go in the same request - see Conventions on nested writes. Card data (`cc_number`, `cc_owner`, `cc_expires`, `cc_type`) is never returned and never accepted. `cc_PNREF` and `cc_AUTHCODE` are gateway references, not card data, and are kept for reconciliation.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "invoicenumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Invoice number. Auto-assigned from the company counter when not supplied."
                    },
                    "ponumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The customer's purchase order number."
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Module that raised the invoice: 2 = manual AR entry, 4 = billed from an order, fulfillment, or service order, 7 = billed from Estimating (print orders), 12 = generated by a payment-plan run, 44 = created by an RMA return."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Orderid. Id only.",
                        "x-idonly": true
                    },
                    "orderbycompanyid": {
                        "type": "integer",
                        "description": "Orderbycompanyid. Id only.",
                        "x-idonly": true
                    },
                    "shiptocompanyid": {
                        "type": "integer",
                        "description": "Shiptocompanyid. Id only.",
                        "x-idonly": true
                    },
                    "status": {
                        "type": "string",
                        "description": "Where the invoice is in its life. Labels are `Arinvoice_model::$statuses`. Stored as int -1/0/1/2/3/4; never exposed or accepted (D35). `unposted` means no GL voucher has been written yet, so lines can still be added; everything else means the ledger has been told.",
                        "enum": [
                            "abandoned",
                            "unposted",
                            "open",
                            "paid",
                            "writeoff",
                            "refundedcredit"
                        ]
                    },
                    "customerbillcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Customer Bill Code printed on the invoice."
                    },
                    "shipcost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "invoicetotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "invoicetermsid": {
                        "type": "integer",
                        "description": "Invoicetermsid. Id only."
                    },
                    "invoiceterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `verbal` of the referenced invoiceterms, instead of the id. Send this or `invoicetermsid`, not both unless they agree."
                    },
                    "salesmanid": {
                        "type": "integer",
                        "description": "Salesmanid. Id only."
                    },
                    "salesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `salesmanid`, not both unless they agree."
                    },
                    "invoicedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Invoice date - the accounting date the invoice posts under."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "discountdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Last date the early-payment discount applies."
                    },
                    "discountamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "accruedinterest": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "datelastinterestcalc": {
                        "type": "string",
                        "format": "date",
                        "description": "When finance-charge interest was last assessed on the invoice.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "payment_method": {
                        "type": "string",
                        "maxLength": 12,
                        "description": "Payment method text carried in from the web store order the invoice came from."
                    },
                    "shipping_method": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Shipping method text carried in from the web store order the invoice came from."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the invoice is raised in."
                    },
                    "transaction_id": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Gateway transaction id of the payment taken with the invoice (web store and POS sales)."
                    },
                    "customers_id": {
                        "type": "integer",
                        "description": "Customers id. Id only."
                    },
                    "customers": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `customers_id`, not both unless they agree."
                    },
                    "currency_value": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "servicerepid": {
                        "type": "integer",
                        "description": "Servicerepid. Id only."
                    },
                    "servicerep": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `servicerepid`, not both unless they agree."
                    },
                    "discountapplied": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "payplan": {
                        "type": "boolean",
                        "description": "True when the invoice is a payment-plan template that generates recurring invoices."
                    },
                    "payplan_period": {
                        "type": "integer",
                        "description": "Recurrence period of the payment plan: 1 = daily, 2 = weekly, 3 = monthly, 4 = quarterly, 5 = yearly; anything else repeats every `payplan_days` days."
                    },
                    "payplan_days": {
                        "type": "integer",
                        "description": "Interval in days between generated invoices, when `payplan_period` does not name a standard period."
                    },
                    "payplan_next": {
                        "type": "string",
                        "format": "date",
                        "description": "Next date the payment plan generates an invoice."
                    },
                    "payplan_numtimes": {
                        "type": "integer",
                        "description": "Remaining number of invoices the plan will generate; -1 repeats indefinitely."
                    },
                    "sales_categoriesid": {
                        "type": "integer",
                        "description": "Sales categoriesid. Id only."
                    },
                    "sales_categories": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `description` of the referenced salescategories, instead of the id. Send this or `sales_categoriesid`, not both unless they agree."
                    },
                    "coverage": {
                        "type": "integer",
                        "description": "1 prints the coverage period - the date range the recurring invoice covers - on generated invoices."
                    },
                    "formnumber": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Form Number of the printed piece, for invoices billed from Estimating."
                    },
                    "shiptoattn": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Attention line printed with the ship-to address."
                    },
                    "old_id": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Invoice id in the system this record was imported from.",
                        "readOnly": true
                    },
                    "client_po": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The customer’s PO number for the invoice."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "arglaccountid": {
                        "type": "integer",
                        "description": "Arglaccountid. Id only."
                    },
                    "arglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `arglaccountid`, not both unless they agree."
                    },
                    "leaseid": {
                        "type": "integer",
                        "description": "Leaseid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "delivered": {
                        "type": "integer",
                        "description": "1 once the invoiced goods are recorded as delivered."
                    },
                    "carrierserviceid_preferred": {
                        "type": "integer",
                        "description": "Carrier service the customer prefers for this shipment."
                    },
                    "b2bhidden": {
                        "type": "boolean",
                        "description": "True hides the invoice from the customer’s B2B portal."
                    },
                    "billtrustsent": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the invoice was sent to the Billtrust delivery service. Maintained by the send flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "contactnameid": {
                        "type": "integer",
                        "description": "Contactnameid. Id only.",
                        "x-idonly": true
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "interestforinvoiceid": {
                        "type": "integer",
                        "description": "Interestforinvoiceid. Id only."
                    },
                    "interestforinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `interestforinvoiceid`, not both unless they agree."
                    },
                    "invoicenotificationmethod": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "How the customer wants this invoice delivered: E = email, M = mail, F = fax. Empty uses the customer default."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "zlienid": {
                        "type": "integer",
                        "description": "Zlienid. Id only.",
                        "x-idonly": true
                    },
                    "emailsent": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the invoice was emailed. Maintained by the send flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "faxsent": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the invoice was faxed. Maintained by the send flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "isacustomerreturn": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "1 when the invoice is a credit raised for a customer return."
                    },
                    "modifiedfromarinvoiceid": {
                        "type": "integer",
                        "description": "Modifiedfromarinvoiceid. Id only."
                    },
                    "modifiedfromarinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `modifiedfromarinvoiceid`, not both unless they agree."
                    },
                    "paiddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the invoice was fully paid.",
                        "readOnly": true
                    },
                    "paymeth": {
                        "type": "integer",
                        "description": "Payment method: 1 = cash, 2 = check, 3 = credit card, 4 = ACH/EFT, 5 = card terminal; 0 = on account or unset."
                    },
                    "priceadjustmentforinvoiceid": {
                        "type": "integer",
                        "description": "Priceadjustmentforinvoiceid. Id only."
                    },
                    "priceadjustmentforinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `priceadjustmentforinvoiceid`, not both unless they agree."
                    },
                    "rental": {
                        "type": "integer",
                        "description": "1 when the invoice bills a rental."
                    },
                    "rentalconverttosale": {
                        "type": "boolean",
                        "description": "True when the invoice converts a rental into a sale."
                    },
                    "taxadjustmentforinvoiceid": {
                        "type": "integer",
                        "description": "Taxadjustmentforinvoiceid. Id only."
                    },
                    "taxadjustmentforinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `taxadjustmentforinvoiceid`, not both unless they agree."
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Taxexemptid. Id only."
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `taxexemptid`, not both unless they agree."
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "billtoshiptoid": {
                        "type": "integer",
                        "description": "Billtoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "defaultassetid": {
                        "type": "integer",
                        "description": "Defaultassetid. Id only.",
                        "x-idonly": true
                    },
                    "passthruarinvoiceid": {
                        "type": "integer",
                        "description": "Passthruarinvoiceid. Id only."
                    },
                    "passthruarinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `passthruarinvoiceid`, not both unless they agree."
                    },
                    "passthrucontactid": {
                        "type": "integer",
                        "description": "Passthrucontactid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerbilltoshiptoid": {
                        "type": "integer",
                        "description": "Passthrucustomerbilltoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerid": {
                        "type": "integer",
                        "description": "Passthrucustomerid. Id only."
                    },
                    "passthrucustomer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `passthrucustomerid`, not both unless they agree."
                    },
                    "passthrufromarinvoiceid": {
                        "type": "integer",
                        "description": "Passthrufromarinvoiceid. Id only."
                    },
                    "passthrufromarinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `passthrufromarinvoiceid`, not both unless they agree."
                    },
                    "specialpurpose": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Marker on system-generated invoices with a special purpose - e.g. CCFEE for credit-card fee invoices - so sales reports can exclude them.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/InvoiceLine"
                        }
                    },
                    "_meta": {
                        "$ref": "#/components/schemas/Meta",
                        "readOnly": true,
                        "description": "Present only when the server has something to report, e.g. the invoice posted but the customer is now over their credit limit."
                    },
                    "affectsinventory": {
                        "type": "boolean",
                        "x-nullable": true,
                        "description": "Whether this invoice withdraws stock. **Leave it out.** Omitted, it is derived, and derived is right in every normal case:\n\n- Invoice raised **from an order or shipment** - stock already left at the shipment, so the invoice moves nothing. Sending `true` here is rejected: it would withdraw the same units twice.\n- **Direct invoice** with stocked lines - it withdraws, because nothing else ever will.\n\nSend `false` only when importing history whose stock was already adjusted by another route. The response then carries an `inventory_not_adjusted` warning, because an invoice that sold goods and moved no stock is a discrepancy someone will chase later."
                    }
                }
            },
            "RefInvoicelines": {
                "type": "object",
                "description": "Lines on an invoice. Normally sent nested inside the invoice rather than created here.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "invoiceid": {
                        "type": "integer",
                        "description": "Invoiceid. Id only."
                    },
                    "invoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `invoiceid`, not both unless they agree."
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position of this line on its document, starting at 1."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line description printed on the invoice."
                    },
                    "qty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "qtyunitnameid": {
                        "type": "integer",
                        "description": "Reference to `unitnames`, by id. Write either this or `qtyunitname`."
                    },
                    "qtyunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `qtyunitnameid`, not both unless they agree."
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "taxflag": {
                        "type": "integer",
                        "description": "Whether the first line tax applies. NolaPro carries up to three taxes per line."
                    },
                    "priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "priceunitnameid": {
                        "type": "integer",
                        "description": "Priceunitnameid. Id only."
                    },
                    "priceunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `priceunitnameid`, not both unless they agree."
                    },
                    "qtyunitperpriceunit": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "totalprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "costeach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "costglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `costglaccount`."
                    },
                    "costglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `costglaccountid`, not both unless they agree."
                    },
                    "main_arinvoicedetailid": {
                        "type": "integer",
                        "description": "Main arinvoicedetailid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptionid": {
                        "type": "integer",
                        "description": "Itemoptionid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptiongroupid": {
                        "type": "integer",
                        "description": "Itemoptiongroupid. Id only.",
                        "x-idonly": true
                    },
                    "taxflag2": {
                        "type": "integer",
                        "description": "Whether the second line tax applies."
                    },
                    "taxflag3": {
                        "type": "integer",
                        "description": "Whether the third line tax applies."
                    },
                    "taxflagid": {
                        "type": "integer",
                        "description": "Taxflagid. Id only.",
                        "x-idonly": true
                    },
                    "taxflag2id": {
                        "type": "integer",
                        "description": "Taxflag2id. Id only.",
                        "x-idonly": true
                    },
                    "taxflag3id": {
                        "type": "integer",
                        "description": "Taxflag3id. Id only.",
                        "x-idonly": true
                    },
                    "orig_priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,5)`.",
                        "x-decimals": 5
                    },
                    "discount_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,5)`.",
                        "x-decimals": 5
                    },
                    "discount_percent": {
                        "type": "string",
                        "description": "Numeric string, 5 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 5,
                        "x-number": true
                    },
                    "old_id": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line id in the system this record was imported from.",
                        "readOnly": true
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "price_override": {
                        "type": "integer",
                        "description": "1 when the price was manually overridden, so repricing leaves it alone."
                    },
                    "extended_price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "worksubtypeid": {
                        "type": "integer",
                        "description": "Worksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "returnqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "returndetailid": {
                        "type": "integer",
                        "description": "Returndetailid. Id only.",
                        "x-idonly": true
                    },
                    "discountid": {
                        "type": "integer",
                        "description": "Discountid. Id only.",
                        "x-idonly": true
                    },
                    "discountpercent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "linedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date recorded for the line (service and rental lines)."
                    },
                    "linetype": {
                        "type": "integer",
                        "description": "Line type: 0 = standard product line, 1 = product-type tax, 2 = delivery charge, 3 = fuel charge, 4 = restock fee, 5 = billed expense."
                    },
                    "partialtaxexemptionid": {
                        "type": "integer",
                        "description": "Partial tax exemption applied to the line."
                    },
                    "partialtaxexemption": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `partialtaxexemptionid`, not both unless they agree."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "arorderdetailid": {
                        "type": "integer",
                        "description": "Arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "itempricespecialdetailid": {
                        "type": "integer",
                        "description": "Itempricespecialdetailid. Id only.",
                        "x-idonly": true
                    },
                    "numperiods": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "period": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Rental period the line bills by: D = daily, W = weekly, M = monthly. Empty for non-rental lines."
                    },
                    "producttypetaxid": {
                        "type": "integer",
                        "description": "Producttypetaxid. Id only.",
                        "x-idonly": true
                    },
                    "rentalbegindate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the rental billing period for the line begins."
                    },
                    "arserviceorder_timeid": {
                        "type": "integer",
                        "description": "Arserviceorder timeid. Id only.",
                        "x-idonly": true
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "description": "Prpaytypeid. Id only.",
                        "x-idonly": true
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefOrders": {
                "type": "object",
                "description": "An order. **One table backs several documents**: `ordertype` is `fulfillment`, `service` or `rental`, and `status` is `quote`, `unconfirmed`, `open`, `partial` or `billed`. A **quote is `status: \"quote\"`** - it is not an order type, and it wins over `ordertype`, so a service order that is still a quote is a quote. The raw integers behind both columns are never exposed.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "ordernumber": {
                        "type": "integer",
                        "description": "Equals `id` - set by the system immediately after insert, kept only for legacy joins. Not a sequence, not money (the column is a double for historical reasons), and never writable. The human-facing number is `onum`.",
                        "readOnly": true
                    },
                    "onum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Display order number when it differs from the record id; imported orders keep their original numbers here."
                    },
                    "ponumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The customer's purchase order number."
                    },
                    "orderbycompanyid": {
                        "type": "integer",
                        "description": "Orderbycompanyid. Id only.",
                        "x-idonly": true
                    },
                    "shiptocompanyid": {
                        "type": "integer",
                        "description": "Shiptocompanyid. Id only.",
                        "x-idonly": true
                    },
                    "status": {
                        "type": "string",
                        "description": "Where the document is in its life. **A quote is a status, not an order type**, and it wins over `ordertype`. Stored as int -1/-2/0/1/2; never exposed or accepted (D35).",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    },
                    "customerbillcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Customer Bill Code printed on order documents."
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "payment_method": {
                        "type": "string",
                        "maxLength": 12,
                        "description": "Payment method text carried in from the web store order."
                    },
                    "shipping_method": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Shipping method text carried in from the web store order."
                    },
                    "orders_date_finished": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the web store marked the order finished."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the order is priced in."
                    },
                    "transaction_id": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Payment gateway reference. Read-only: written by the gateway, never by a caller.",
                        "readOnly": true
                    },
                    "customers_id": {
                        "type": "integer",
                        "description": "Customer id in the osCommerce-style web store tables, for cart integrations."
                    },
                    "customers": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `customers_id`, not both unless they agree."
                    },
                    "shipping_cost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "order_weight": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "currency_value": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "wherefrom": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Module or channel that created the order; empty for orders entered in NolaPro."
                    },
                    "confirmed_by": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Who confirmed the order."
                    },
                    "confirmed_date": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Date the order was confirmed."
                    },
                    "confirmed": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "1 once the order is confirmed with the customer."
                    },
                    "paymeth": {
                        "type": "integer",
                        "description": "Payment method: 1 = cash, 2 = check, 3 = credit card, 4 = ACH/EFT, 5 = card terminal; 0 = on account or unset."
                    },
                    "ordertype": {
                        "type": "string",
                        "description": "What kind of document this is. Stored as int 0/1/2; the integer is never exposed or accepted (D35).",
                        "enum": [
                            "fulfillment",
                            "service",
                            "rental"
                        ]
                    },
                    "estimate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "deposit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "salesmanid": {
                        "type": "integer",
                        "description": "Reference to `salesmen`, by id. Write either this or `salesman`."
                    },
                    "salesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `salesmanid`, not both unless they agree."
                    },
                    "sales_categoriesid": {
                        "type": "integer",
                        "description": "Sales category the order reports under."
                    },
                    "sales_categories": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `description` of the referenced salescategories, instead of the id. Send this or `sales_categoriesid`, not both unless they agree."
                    },
                    "statusid": {
                        "type": "integer",
                        "description": "Statusid. Id only.",
                        "x-idonly": true
                    },
                    "rma_arorder_returnedid": {
                        "type": "integer",
                        "description": "Rma arorder returnedid. Id only.",
                        "x-idonly": true
                    },
                    "rma_orig_arorderid": {
                        "type": "integer",
                        "description": "Rma orig arorderid. Id only.",
                        "x-idonly": true
                    },
                    "carrierserviceid_preferred": {
                        "type": "integer",
                        "description": "Carrier service the customer prefers for shipping this order."
                    },
                    "finalship": {
                        "type": "integer",
                        "description": "1 when the order is Marked Final - no more shipments are expected."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "arglaccountid": {
                        "type": "integer",
                        "description": "Arglaccountid. Id only."
                    },
                    "arglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `arglaccountid`, not both unless they agree."
                    },
                    "defaultworktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `defaultworktype`."
                    },
                    "defaultworktype": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced worktypes, instead of the id. Send this or `defaultworktypeid`, not both unless they agree."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "defaultworksubtypeid": {
                        "type": "integer",
                        "description": "Defaultworksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "stageid": {
                        "type": "integer",
                        "description": "Stageid. Id only.",
                        "x-idonly": true
                    },
                    "edi": {
                        "type": "integer",
                        "description": "1 when the order arrived through EDI."
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "outsidesalesmargin": {
                        "type": "integer",
                        "description": "Margin percentage used for outside-sales commission on the order; -1 when the margin was overridden."
                    },
                    "ediasn": {
                        "type": "integer",
                        "description": "1 once the EDI advance ship notice (ASN) has been sent for the order."
                    },
                    "ediinvoice": {
                        "type": "integer",
                        "description": "1 once the invoice has been sent through EDI."
                    },
                    "lastshipdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date of the most recent shipment on the order.",
                        "readOnly": true
                    },
                    "defaultvendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `defaultvendor`."
                    },
                    "defaultvendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `defaultvendorid`, not both unless they agree."
                    },
                    "shippingnotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Shippingnotes. Stored as `text`, no practical length limit."
                    },
                    "contactnameid": {
                        "type": "integer",
                        "description": "Contactnameid. Id only.",
                        "x-idonly": true
                    },
                    "dropship": {
                        "type": "boolean",
                        "description": "True when the order drop-ships from the vendor directly to the customer."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "pickticklastprint": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the pick ticket was last printed. Maintained by the print flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "pickticknumprint": {
                        "type": "integer",
                        "description": "How many times the pick ticket has printed. Maintained by the print flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "revision": {
                        "type": "integer",
                        "description": "Revision counter, incremented each time the order is edited with changes.",
                        "readOnly": true
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "unread": {
                        "type": "boolean",
                        "description": "1 until someone opens the order in NolaPro; new web and B2B orders arrive unread."
                    },
                    "clonedquotearorderid": {
                        "type": "integer",
                        "description": "Clonedquotearorderid. Id only.",
                        "x-idonly": true
                    },
                    "ordertotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "rentalsbillwhen": {
                        "type": "boolean",
                        "description": "For rental orders: when rentals bill (0 = on return, 1 = periodically while out)."
                    },
                    "signaturerequired": {
                        "type": "boolean",
                        "description": "1 when delivery requires a signature."
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Reference to `taxexempts`, by id. Write either this or `taxexempt`."
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `taxexemptid`, not both unless they agree."
                    },
                    "usecontactdetails": {
                        "type": "boolean",
                        "description": "1 prints the order contact’s details on documents instead of the customer’s main details."
                    },
                    "billtoshiptoid": {
                        "type": "integer",
                        "description": "Billtoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "defaultassetid": {
                        "type": "integer",
                        "description": "Defaultassetid. Id only.",
                        "x-idonly": true
                    },
                    "effective_status": {
                        "type": "integer",
                        "description": "Cached derived status used by order lists: -98 = cancelled, -97 = complete, -96 = out on rent, otherwise the order status code. Maintained by the calculation cache, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "passthrucontactid": {
                        "type": "integer",
                        "description": "Passthrucontactid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerbilltoshiptoid": {
                        "type": "integer",
                        "description": "Passthrucustomerbilltoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerid": {
                        "type": "integer",
                        "description": "Passthrucustomerid. Id only."
                    },
                    "passthrucustomer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `passthrucustomerid`, not both unless they agree."
                    },
                    "ordernumberdisplay": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "readOnly": true
                    },
                    "estimatedmultiplier": {
                        "type": "integer",
                        "description": "Estimated Multiplier applied when estimating the order’s pricing."
                    },
                    "hidebettervalueinfopdf": {
                        "type": "integer",
                        "description": "1 hides the better-value pricing block on the printed quote PDF."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefOrderlines": {
                "type": "object",
                "description": "Lines on an order. Normally sent nested inside the order.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Orderid. Id only.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position of this line on its document, starting at 1."
                    },
                    "qtyorder": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "qtyship": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "qtybill": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "taxflag": {
                        "type": "integer",
                        "description": "Whether the first line tax applies. NolaPro carries up to three taxes per line."
                    },
                    "costeach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "products_tax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,4)`.",
                        "x-decimals": 4
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line description printed on the order."
                    },
                    "saleunitperpriceunit": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "costglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `costglaccount`."
                    },
                    "costglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `costglaccountid`, not both unless they agree."
                    },
                    "purchaseunitid": {
                        "type": "integer",
                        "description": "Unit the line is purchased in, from `unitnames`."
                    },
                    "purchaseunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `purchaseunitid`, not both unless they agree."
                    },
                    "priceunitid": {
                        "type": "integer",
                        "description": "Unit the line is priced in, from `unitnames`."
                    },
                    "priceunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `priceunitid`, not both unless they agree."
                    },
                    "main_arorderdetailid": {
                        "type": "integer",
                        "description": "Main arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptiongroupid": {
                        "type": "integer",
                        "description": "Itemoptiongroupid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptionid": {
                        "type": "integer",
                        "description": "Itemoptionid. Id only.",
                        "x-idonly": true
                    },
                    "multioption": {
                        "type": "integer",
                        "description": "1 when the line is an option row belonging to a multi-option (options item) main line."
                    },
                    "optionindependent": {
                        "type": "integer",
                        "description": "1 when the option line’s quantity is independent of the main item’s quantity."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "taxflag2": {
                        "type": "integer",
                        "description": "Whether the second line tax applies."
                    },
                    "taxflag3": {
                        "type": "integer",
                        "description": "Whether the third line tax applies."
                    },
                    "taxflagid": {
                        "type": "integer",
                        "description": "Taxflagid. Id only.",
                        "x-idonly": true
                    },
                    "taxflag2id": {
                        "type": "integer",
                        "description": "Taxflag2id. Id only.",
                        "x-idonly": true
                    },
                    "taxflag3id": {
                        "type": "integer",
                        "description": "Taxflag3id. Id only.",
                        "x-idonly": true
                    },
                    "itemweight": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "qtyorderprice": {
                        "type": "string",
                        "description": "Quantity, stored as double, as a string. Stored as `double`.",
                        "x-qty": true
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "price_override": {
                        "type": "integer",
                        "description": "1 when the price was manually overridden, so repricing leaves it alone."
                    },
                    "extended_price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "worksubtypeid": {
                        "type": "integer",
                        "description": "Worksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "discount_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "orig_priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "linedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date recorded for the line (service and rental lines)."
                    },
                    "linetype": {
                        "type": "integer",
                        "description": "Line type: 0 = standard product line, 1 = product-type tax, 2 = delivery charge, 3 = fuel charge, 4 = restock fee, 5 = billed expense."
                    },
                    "partialtaxexemptionid": {
                        "type": "integer",
                        "description": "Partial tax exemption applied to the line."
                    },
                    "partialtaxexemption": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `partialtaxexemptionid`, not both unless they agree."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "transfrominventorylocationid": {
                        "type": "integer",
                        "description": "Reference to `inventorylocations`, by id. Write either this or `transfrominventorylocation`."
                    },
                    "transfrominventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `transfrominventorylocationid`, not both unless they agree."
                    },
                    "createpowhenconvertedfrombid": {
                        "type": "boolean",
                        "description": "True creates a purchase order for the line when the quote converts to an order."
                    },
                    "ignoretaxexempt": {
                        "type": "boolean",
                        "description": "True taxes the line even when the customer is tax exempt."
                    },
                    "itempricespecialdetailid": {
                        "type": "integer",
                        "description": "Itempricespecialdetailid. Id only.",
                        "x-idonly": true
                    },
                    "numperiods": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "period": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Rental period the line bills by: D = daily, W = weekly, M = monthly. Empty for non-rental lines."
                    },
                    "producttypetaxid": {
                        "type": "integer",
                        "description": "Producttypetaxid. Id only.",
                        "x-idonly": true
                    },
                    "arserviceorder_timeid": {
                        "type": "integer",
                        "description": "Arserviceorder timeid. Id only.",
                        "x-idonly": true
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "assetidlastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the rental asset assigned to the line last changed.",
                        "readOnly": true
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "description": "Prpaytypeid. Id only.",
                        "x-idonly": true
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefShipments": {
                "type": "object",
                "description": "A shipment against an order.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Orderid. Id only.",
                        "x-idonly": true
                    },
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Carrier service the shipment goes out by."
                    },
                    "carrierservice": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrierservice, instead of the id."
                    },
                    "shipdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it went out."
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Shiptoid. Id only.",
                        "x-idonly": true
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "invoiceid": {
                        "type": "integer",
                        "description": "Invoiceid. Id only."
                    },
                    "invoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `invoiceid`, not both unless they agree."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefShipmentlines": {
                "type": "object",
                "description": "What was shipped, per line.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "ordershipid": {
                        "type": "integer",
                        "description": "Ordershipid. Id only.",
                        "x-idonly": true
                    },
                    "orderdetailid": {
                        "type": "integer",
                        "description": "Orderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "shipqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "inventoryglacctid": {
                        "type": "integer",
                        "description": "Inventoryglacctid. Id only."
                    },
                    "inventoryglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `inventoryglacctid`, not both unless they agree."
                    },
                    "costeach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "adjustmentqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "adjustmentqtysansonhand": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "lastrentalbilldate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date rental on the shipped line was last billed through."
                    },
                    "minrentalbilldate": {
                        "type": "string",
                        "format": "date",
                        "description": "Earliest date rental on the line may bill from."
                    },
                    "rentalisoffrent": {
                        "type": "boolean",
                        "description": "True once the rental item has come off rent."
                    },
                    "rentalissold": {
                        "type": "boolean",
                        "description": "True when the rented item was sold to the customer instead of returned."
                    },
                    "rentaloffrentdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the item came off rent."
                    },
                    "rentaloffrentqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "rentalreturncomplete": {
                        "type": "boolean",
                        "description": "True once the rental return is complete."
                    },
                    "rentalreturndate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the rental item was returned."
                    },
                    "rentalreturnqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "rentalsolddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the rented item was sold to the customer."
                    },
                    "rentalsoldqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "rentalvalue": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefPayments": {
                "type": "object",
                "description": "Payments applied to an invoice.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "invoiceid": {
                        "type": "integer",
                        "description": "Invoiceid. Id only."
                    },
                    "invoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `invoiceid`, not both unless they agree."
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "datereceived": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the payment was received - the accounting date it posts under."
                    },
                    "paymeth": {
                        "type": "integer",
                        "description": "Payment method code: 1 = cash, 2 = check (the POS writes 2 for credit card), 3 = credit card, 4 = ACH/EFT, 5 = POS card terminal, 99 = write-off; 0 = on account or unset."
                    },
                    "interest": {
                        "type": "integer",
                        "description": "1 when the payment pays finance-charge interest rather than invoice principal."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "cancel_userid": {
                        "type": "integer",
                        "description": "User who voided the payment.",
                        "readOnly": true
                    },
                    "cancel_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `cancel_userid`, not both unless they agree."
                    },
                    "checkid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Check number or payment reference the customer paid with."
                    },
                    "bankdepositid": {
                        "type": "integer",
                        "description": "Bankdepositid. Id only.",
                        "x-idonly": true
                    },
                    "bankstatement_enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "End date of the bank statement the payment was reconciled under. Maintained by bank reconciliation, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "old_id": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Payment id in the system this record was imported from.",
                        "readOnly": true
                    },
                    "refund_paymeth": {
                        "type": "integer",
                        "description": "Payment method used for the refund, when the payment is a refund."
                    },
                    "cctransactionid": {
                        "type": "integer",
                        "description": "Cctransactionid. Id only.",
                        "x-idonly": true
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the payment was received in."
                    },
                    "returned": {
                        "type": "integer",
                        "description": "1 when the payment was returned by the bank (NSF/bounced)."
                    },
                    "feeinvoiceid": {
                        "type": "integer",
                        "description": "Feeinvoiceid. Id only."
                    },
                    "feeinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `feeinvoiceid`, not both unless they agree."
                    },
                    "feeapbillid": {
                        "type": "integer",
                        "description": "Feeapbillid. Id only.",
                        "x-idonly": true
                    },
                    "bankfee_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "bankfee_glid": {
                        "type": "integer",
                        "description": "GL account a bank fee taken out of the payment posts to."
                    },
                    "bankfee_gl": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `bankfee_glid`, not both unless they agree."
                    },
                    "rnum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Reference number recorded with the payment (remittance or voucher reference)."
                    },
                    "tendered": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "transid": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Gateway transaction id, for card and online payments."
                    },
                    "orderdepositid": {
                        "type": "integer",
                        "description": "Orderdepositid. Id only.",
                        "x-idonly": true
                    },
                    "ccterminalid": {
                        "type": "integer",
                        "description": "Ccterminalid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "isb2bpayment": {
                        "type": "boolean",
                        "description": "True when the customer paid through the B2B portal."
                    },
                    "isb2bpaymentfee": {
                        "type": "boolean",
                        "description": "True when the record is the convenience fee charged on a B2B portal payment."
                    },
                    "jointcheck": {
                        "type": "boolean",
                        "description": "True when the payment is a joint check (AR joint checks feature)."
                    },
                    "bankstatement_cleardate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the payment cleared the bank. Maintained by bank reconciliation, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "extuserid": {
                        "type": "integer",
                        "description": "Extuserid. Id only.",
                        "x-idonly": true
                    },
                    "ispaymentonaccount": {
                        "type": "boolean",
                        "description": "True when the payment is on account rather than applied to a specific invoice."
                    },
                    "writeoffreasonid": {
                        "type": "integer",
                        "description": "Write-off reason (`writeoffreason` id) when the payment is a write-off (`paymeth` 99).",
                        "x-idonly": true
                    },
                    "creditfromarinvoicepaymentdetailid": {
                        "type": "integer",
                        "description": "Creditfromarinvoicepaymentdetailid. Id only.",
                        "x-idonly": true
                    },
                    "credittoarinvoicepaymentdetailid": {
                        "type": "integer",
                        "description": "Credittoarinvoicepaymentdetailid. Id only.",
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "datereceivedandvoucherid": {
                        "type": "integer",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "pendingarachbankrecdatereceived": {
                        "type": "string",
                        "format": "date",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "readOnly": true
                    },
                    "creditorderdepositid": {
                        "type": "integer",
                        "description": "Creditorderdepositid. Id only.",
                        "x-idonly": true
                    },
                    "checkaccountid": {
                        "type": "integer",
                        "description": "Checking account the payment was deposited to."
                    },
                    "checkaccount": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `name` of the referenced checkaccounts, instead of the id. Send this or `checkaccountid`, not both unless they agree."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefPurchaseorders": {
                "type": "object",
                "description": "Purchase orders to a vendor.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "ponumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The customer's purchase order number."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Carrier service the purchase order ships by."
                    },
                    "carrierservice": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrierservice, instead of the id."
                    },
                    "tracknumber": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Carrier tracking number."
                    },
                    "contact": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Vendor contact for the purchase order."
                    },
                    "requisition": {
                        "type": "string",
                        "maxLength": 22,
                        "description": "Requisition reference."
                    },
                    "ordernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Order # of the sales order this PO buys for, when the PO was pulled from an order."
                    },
                    "complete": {
                        "type": "integer",
                        "description": "1 when the PO is complete - fully received or manually closed; no further receipts are expected."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Referenceid. Id only.",
                        "x-idonly": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "initials": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Buyer initials shown on the PO."
                    },
                    "status": {
                        "type": "string",
                        "description": "A proposal is the PO version of a quote - one field flip converts it. `Partial` and `Complete` are not statuses: see `effectivestatus` and `complete`. Stored as int -1/0; never exposed (D35).",
                        "enum": [
                            "proposal",
                            "open"
                        ]
                    },
                    "effectivestatus": {
                        "type": "string",
                        "enum": [
                            "proposal",
                            "open",
                            "partial",
                            "complete"
                        ],
                        "readOnly": true,
                        "description": "What the PO list screen shows. `partial` is **computed** from whether receipts exist - it is not stored, so it cannot be written; sending it is rejected like any read-only field."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Purchase order description."
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Where the PO originated; 0 for POs entered on the purchase order screen."
                    },
                    "salesordernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Sales Order Number reference shown on the PO."
                    },
                    "dropship": {
                        "type": "integer",
                        "description": "1 when the PO drop-ships from the vendor directly to the customer."
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Shiptoid. Id only.",
                        "x-idonly": true
                    },
                    "salesorderid": {
                        "type": "integer",
                        "description": "Salesorderid. Id only.",
                        "x-idonly": true
                    },
                    "paytermsid": {
                        "type": "integer",
                        "description": "Paytermsid. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead."
                    },
                    "payterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced invoiceterms, instead of the id."
                    },
                    "ccpurchaseid": {
                        "type": "integer",
                        "description": "Ccpurchaseid. Id only.",
                        "x-idonly": true
                    },
                    "stageid": {
                        "type": "integer",
                        "description": "Stageid. Id only.",
                        "x-idonly": true
                    },
                    "recipient_userid": {
                        "type": "integer",
                        "description": "User who will receive the goods."
                    },
                    "recipient_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `recipient_userid`, not both unless they agree."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "totaltax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "main_invpoid": {
                        "type": "integer",
                        "description": "Main invpoid. Id only.",
                        "x-idonly": true
                    },
                    "prior_invpoid": {
                        "type": "integer",
                        "description": "Prior invpoid. Id only.",
                        "x-idonly": true
                    },
                    "retainage": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "fob": {
                        "type": "string",
                        "maxLength": 2,
                        "description": "FOB terms printed on the PO."
                    },
                    "chargeback": {
                        "type": "integer",
                        "description": "1 when the PO is charged back to another vendor."
                    },
                    "chargeback_vendorid": {
                        "type": "integer",
                        "description": "Vendor the chargeback PO is charged back to."
                    },
                    "chargeback_vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `chargeback_vendorid`, not both unless they agree."
                    },
                    "chargeback_invpoid": {
                        "type": "integer",
                        "description": "Chargeback invpoid. Id only.",
                        "x-idonly": true
                    },
                    "chargeback_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "pototal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the PO is priced in."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "return_from_invpoid": {
                        "type": "integer",
                        "description": "Return from invpoid. Id only.",
                        "x-idonly": true
                    },
                    "rtvnumber": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "RTV number, for a return-to-vendor PO."
                    },
                    "vendor_orderfromid": {
                        "type": "integer",
                        "description": "Vendor orderfromid. Id only.",
                        "x-idonly": true
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the PO ship-to address."
                    },
                    "completedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the PO was completed."
                    },
                    "customerdropshiptoid": {
                        "type": "integer",
                        "description": "Customer ship-to address a drop-ship PO delivers to."
                    },
                    "customerdropshipto": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `customerdropshiptoid`, not both unless they agree."
                    },
                    "donotupdatelastpocost": {
                        "type": "boolean",
                        "description": "True keeps receipts on this PO from updating the item’s last PO cost (Do Not Update Last PO Cost)."
                    },
                    "headernote": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Headernote. Stored as `text`, no practical length limit."
                    },
                    "prepaid": {
                        "type": "integer",
                        "description": "Prepaid. Id only.",
                        "x-idonly": true
                    },
                    "shipname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Ship To name printed on the PO."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the PO ship-to address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefPurchaseorderlines": {
                "type": "object",
                "description": "Lines on a purchase order. Normally sent nested inside the PO.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "invpoid": {
                        "type": "integer",
                        "description": "Invpoid. Id only.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "itemqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "itemprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "detail_description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line description printed on the PO."
                    },
                    "inv_glacct": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "conversion": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "itemvendorid": {
                        "type": "integer",
                        "description": "Itemvendorid. Id only.",
                        "x-idonly": true
                    },
                    "purchaseunitid": {
                        "type": "integer",
                        "description": "Unit the line is purchased in, from `unitnames`."
                    },
                    "purchaseunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `purchaseunitid`, not both unless they agree."
                    },
                    "itempriceqty": {
                        "type": "string",
                        "description": "Quantity, 5 decimal places, as a string. Stored as `decimal(5dp)`.",
                        "x-decimals": 5,
                        "x-qty": true
                    },
                    "notes": {
                        "type": "string",
                        "maxLength": 500,
                        "description": "Free-form notes on the line."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "taxable": {
                        "type": "integer",
                        "description": "Whether this line is taxed."
                    },
                    "detailrow": {
                        "type": "integer",
                        "description": "Position of the line on the PO."
                    },
                    "tax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "reqshipdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Ship date requested from the vendor for this line."
                    },
                    "accepted": {
                        "type": "integer",
                        "description": "1 once the line is marked Accepted on the PO screen."
                    },
                    "arorderdetailid": {
                        "type": "integer",
                        "description": "Arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "donotupdatelastpocost": {
                        "type": "boolean",
                        "description": "True keeps receipts of this line from updating the item’s last PO cost."
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position of this line on its document, starting at 1."
                    },
                    "linetype": {
                        "type": "integer",
                        "description": "Line type: 0 = standard product line; other values mark charge lines."
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "createasset": {
                        "type": "boolean",
                        "description": "True creates a fixed asset from the line when it is received."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefEstquotes": {
                "type": "object",
                "description": "Quotes from the Estimating module. A **different thing** from an AR quote, which is an `order` with `status` `quote`. `ordertype` 2 is a rental order, not a quote.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "contactname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Customer contact the quote is for."
                    },
                    "stdsizeid": {
                        "type": "integer",
                        "description": "Stdsizeid. Id only.",
                        "x-idonly": true
                    },
                    "cwidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,3)`.",
                        "x-decimals": 3
                    },
                    "clength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,3)`.",
                        "x-decimals": 3
                    },
                    "substockid": {
                        "type": "integer",
                        "description": "Paper stock the job prints on (the Stock picker on the quote form)."
                    },
                    "substock": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `substockid`, not both unless they agree."
                    },
                    "tightreg1": {
                        "type": "integer",
                        "description": "1 when side 1 requires tight registration; the option appears when more than one ink is selected."
                    },
                    "tightreg2": {
                        "type": "integer",
                        "description": "1 when side 2 requires tight registration."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Job description."
                    },
                    "substockcolorid": {
                        "type": "integer",
                        "description": "Substockcolorid. Id only.",
                        "x-idonly": true
                    },
                    "shippingservice": {
                        "type": "string",
                        "maxLength": 3,
                        "description": "Shipping service quoted for delivery."
                    },
                    "shippingzipcode": {
                        "type": "string",
                        "maxLength": 12,
                        "description": "Destination ZIP code used to quote shipping."
                    },
                    "special": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Special Notes for the job."
                    },
                    "quotenum": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Quote number shown to the customer."
                    },
                    "extuser": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "genuser": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "pricelistid": {
                        "type": "integer",
                        "description": "Pricelistid. Id only.",
                        "x-idonly": true
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "finalshipdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the job actually shipped."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Estquotequote_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "quote",
                            "open",
                            "confirmed",
                            "partiallyshipped",
                            "shipped",
                            "complete",
                            "unconfirmedexternal",
                            "unconfirmedinternal",
                            "inprogress"
                        ]
                    },
                    "billdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the job was billed."
                    },
                    "order_quantity": {
                        "type": "integer",
                        "description": "Quantity ordered."
                    },
                    "shiptotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "billtotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "orderdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the quote became an order."
                    },
                    "instructions": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Production instructions printed on the job ticket."
                    },
                    "id_printorder": {
                        "type": "integer",
                        "description": "Print order (job) number assigned when the quote becomes an order; 0 while it is still a quote."
                    },
                    "extras": {
                        "type": "integer",
                        "description": "Extra Sheets Scrap - additional sheets run to cover setup and spoilage."
                    },
                    "numup": {
                        "type": "integer",
                        "description": "Number Up On Press Sheet - how many pieces print per sheet."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "papername": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Paper name printed on the job ticket."
                    },
                    "paperwidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,3)`.",
                        "x-decimals": 3
                    },
                    "paperlength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,3)`.",
                        "x-decimals": 3
                    },
                    "priority": {
                        "type": "integer",
                        "description": "Production priority used to sequence jobs."
                    },
                    "formnumber": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Form Number of the printed piece."
                    },
                    "numparts": {
                        "type": "integer",
                        "description": "Number of parts in the piece (multi-part carbonless forms)."
                    },
                    "salesglacctid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `salesglacct`."
                    },
                    "salesglacct": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `salesglacctid`, not both unless they agree."
                    },
                    "presslength": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "presswidth": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "customer_po": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Customer PO number for the job."
                    },
                    "print_how": {
                        "type": "integer",
                        "description": "Press imposition: 0 = none, 1 = Work & Turn, 2 = Work & Flop."
                    },
                    "rush_charge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "composition_charge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "glrush": {
                        "type": "integer",
                        "description": "GL account rush charges post to; seeded from the print module default."
                    },
                    "glcomposition": {
                        "type": "integer",
                        "description": "GL account composition (typesetting) charges post to; seeded from the print module default."
                    },
                    "reprint": {
                        "type": "integer",
                        "description": "1 when the job is a reprint of an earlier printing."
                    },
                    "printdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the job printed."
                    },
                    "calculated_qty": {
                        "type": "string",
                        "description": "Quantity, 5 decimal places, as a string. Stored as `decimal(5dp)`.",
                        "x-decimals": 5,
                        "x-qty": true
                    },
                    "sell_total": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,5)`.",
                        "x-decimals": 5
                    },
                    "calculated_total": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(14,5)`.",
                        "x-decimals": 5
                    },
                    "previous_id_printorder": {
                        "type": "integer",
                        "description": "The earlier print order a reprint or reorder was copied from; artwork carries over from it."
                    },
                    "client_notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Client_notes. Stored as `text`, no practical length limit."
                    },
                    "confirm_date": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the order was confirmed with the customer."
                    },
                    "sigmult": {
                        "type": "integer",
                        "description": "Number of Sigs - signatures making up the piece."
                    },
                    "invoiceto_companyid": {
                        "type": "integer",
                        "description": "Invoiceto companyid. Id only.",
                        "x-idonly": true
                    },
                    "order_discount_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "preferred_shipdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Ship date the customer asked for."
                    },
                    "receivedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the order was received."
                    },
                    "shipbefore": {
                        "type": "string",
                        "format": "date",
                        "description": "Latest date the job may ship."
                    },
                    "shipafter": {
                        "type": "integer",
                        "description": "Ship XX Days After Approval - days to wait after proof approval before shipping."
                    },
                    "orderyear": {
                        "type": "string",
                        "maxLength": 4,
                        "description": "Order Year bucket the job number belongs to; print order numbering restarts each year."
                    },
                    "art_number": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Art # - artwork reference for the job."
                    },
                    "reorder": {
                        "type": "integer",
                        "description": "1 when this order is a reorder of a previous job."
                    },
                    "ordertaker": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Order Taken By - who took the order."
                    },
                    "problem": {
                        "type": "integer",
                        "description": "1 flags a Problem Order for follow-up."
                    },
                    "rush": {
                        "type": "integer",
                        "description": "1 marks the job as a rush order."
                    },
                    "order_sourceid": {
                        "type": "integer",
                        "description": "Order sourceid. Id only.",
                        "x-idonly": true
                    },
                    "sales_responseid": {
                        "type": "integer",
                        "description": "Sales responseid. Id only.",
                        "x-idonly": true
                    },
                    "shipnote": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Ship Note printed on shipping paperwork."
                    },
                    "ok": {
                        "type": "integer",
                        "description": "1 once the customer’s proof approval (OK to print) is recorded."
                    },
                    "okdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the proof approval was recorded."
                    },
                    "topress": {
                        "type": "integer",
                        "description": "1 once the job is Released to Press."
                    },
                    "topressdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the job was released to press."
                    },
                    "print_what_on_covers": {
                        "type": "integer",
                        "description": "For printed covers: 0 = N/A, 1 = print names and addresses, 2 = print names only."
                    },
                    "coupon_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(16,5)`.",
                        "x-decimals": 5
                    },
                    "couponid": {
                        "type": "integer",
                        "description": "Couponid. Id only.",
                        "x-idonly": true
                    },
                    "rescom": {
                        "type": "integer",
                        "description": "Whether the delivery address is commercial or residential, from the Commercial or Residential selector."
                    },
                    "pricepercover": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "priceperspecialdesign": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "pricepercolorborder": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "priceperpremium": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "priceperstandard": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "totalpriceperbook": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "basepriceperbook": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "totaldiscountamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefAssets": {
                "type": "object",
                "description": "Fixed assets.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Asset name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "assetcategoryid": {
                        "type": "integer",
                        "description": "Assetcategoryid. Id only.",
                        "x-idonly": true
                    },
                    "manufacturervendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `manufacturervendor`."
                    },
                    "manufacturervendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `manufacturervendorid`, not both unless they agree."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "cost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the asset was purchased in."
                    },
                    "purchasedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the asset was purchased."
                    },
                    "disposeddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the asset was disposed of."
                    },
                    "serialnumber": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Serial number of the asset."
                    },
                    "manufacturedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the asset was manufactured."
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Shiptoid. Id only.",
                        "x-idonly": true
                    },
                    "ownertype": {
                        "type": "integer",
                        "description": "Who owns the asset: 0 = company, 1 = customer, 2 = vendor. Only company-owned fixed assets depreciate."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "modelnumber": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Model number of the asset."
                    },
                    "assettype": {
                        "type": "integer",
                        "description": "Asset class: 0 = fixed asset, 1 = current asset, 2 = intangible asset, 3 = investment. Only fixed assets depreciate."
                    },
                    "salvagevalue": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "usefullifeinyears": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "assetglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `assetglaccount`."
                    },
                    "assetglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `assetglaccountid`, not both unless they agree."
                    },
                    "accumulateddepreciationglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `accumulateddepreciationglaccount`."
                    },
                    "accumulateddepreciationglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `accumulateddepreciationglaccountid`, not both unless they agree."
                    },
                    "expenseglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `expenseglaccount`."
                    },
                    "expenseglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `expenseglaccountid`, not both unless they agree."
                    },
                    "parentassetid": {
                        "type": "integer",
                        "description": "Parentassetid. Id only.",
                        "x-idonly": true
                    },
                    "invpoid": {
                        "type": "integer",
                        "description": "Invpoid. Id only.",
                        "x-idonly": true
                    },
                    "invpodetailid": {
                        "type": "integer",
                        "description": "Invpodetailid. Id only.",
                        "x-idonly": true
                    },
                    "apbillid": {
                        "type": "integer",
                        "description": "Apbillid. Id only.",
                        "x-idonly": true
                    },
                    "apbilldetailid": {
                        "type": "integer",
                        "description": "Apbilldetailid. Id only.",
                        "x-idonly": true
                    },
                    "arinvoiceid": {
                        "type": "integer",
                        "description": "Arinvoiceid. Id only."
                    },
                    "arinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `arinvoiceid`, not both unless they agree."
                    },
                    "arinvoicedetailid": {
                        "type": "integer",
                        "description": "Arinvoicedetailid. Id only.",
                        "x-idonly": true
                    },
                    "arorderid": {
                        "type": "integer",
                        "description": "Arorderid. Id only.",
                        "x-idonly": true
                    },
                    "arorderdetailid": {
                        "type": "integer",
                        "description": "Arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "clonedfromassetid": {
                        "type": "integer",
                        "description": "Clonedfromassetid. Id only.",
                        "x-idonly": true
                    },
                    "invreceiveitemtransactionid": {
                        "type": "integer",
                        "description": "Invreceiveitemtransactionid. Id only.",
                        "x-idonly": true
                    },
                    "assetitemtransactionid": {
                        "type": "integer",
                        "description": "Assetitemtransactionid. Id only.",
                        "x-idonly": true
                    },
                    "returnassetitemtransactionid": {
                        "type": "integer",
                        "description": "Returnassetitemtransactionid. Id only.",
                        "x-idonly": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "depreciationcalculationmethod": {
                        "type": "integer",
                        "description": "Depreciation method: 0 = straight line, 1 = double declining balance, 2 = units of production."
                    },
                    "depreciationcalculatedasof": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date depreciation has been calculated through. Maintained by the depreciation run, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "usefullifeinproductionunits": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "inventoryglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `inventoryglaccount`."
                    },
                    "inventoryglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `inventoryglaccountid`, not both unless they agree."
                    },
                    "expensedepreciationglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `expensedepreciationglaccount`."
                    },
                    "expensedepreciationglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `expensedepreciationglaccountid`, not both unless they agree."
                    },
                    "assetvoucherid": {
                        "type": "integer",
                        "description": "Assetvoucherid. Id only."
                    },
                    "assetvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `assetvoucherid`, not both unless they agree."
                    },
                    "manufacturer": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Manufacturer of the asset."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefAssetcategories": {
                "type": "object",
                "description": "Grouping for fixed assets.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the asset category."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "accumulateddepreciationglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `accumulateddepreciationglaccount`."
                    },
                    "accumulateddepreciationglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `accumulateddepreciationglaccountid`, not both unless they agree."
                    },
                    "assetglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `assetglaccount`."
                    },
                    "assetglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `assetglaccountid`, not both unless they agree."
                    },
                    "expenseglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `expenseglaccount`."
                    },
                    "expenseglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `expenseglaccountid`, not both unless they agree."
                    },
                    "expensedepreciationglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `expensedepreciationglaccount`."
                    },
                    "expensedepreciationglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `expensedepreciationglaccountid`, not both unless they agree."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefB2busers": {
                "type": "object",
                "description": "Customer-portal logins. Credentials are never returned.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "firstname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The portal user’s first name."
                    },
                    "lastname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The portal user’s last name."
                    },
                    "loginname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Login name for the B2B portal. Customers and vendors sign in to the portal with this, not with a NolaPro user account."
                    },
                    "usertype": {
                        "type": "integer",
                        "description": "What kind of portal user this is: 1 = customer contact, 2 = vendor contact, 0 = self-registered appointments login (no linked record). Legacy values 3 and 4 are treated as vendor."
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "The customer id (`usertype` 1) or vendor id (`usertype` 2) this login belongs to. Polymorphic, so there is no code sibling - send the id.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "email": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email address. Password resets and portal notifications go here."
                    },
                    "viewedprivacypolicymessage": {
                        "type": "integer",
                        "description": "Set to 1 when the portal user dismisses the privacy-policy notice. It records the user’s own acknowledgment, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "wpemailconfirmed": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email address the appointments (external WordPress) login flow has verified. Set only when the user completes the emailed verification link, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "wpemailunconfirmed": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Address awaiting verification in the appointments login flow. Moves to `wpemailconfirmed` when the user clicks the emailed link.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefServiceordertimes": {
                "type": "object",
                "description": "Hours logged against a service order (an `order` with `ordertype` `service`). Hours are not order lines: they become lines only when billed, at which point the record is frozen. `totalprice`, `totalcost` and `baserate` are derived and never accepted.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "employeeid": {
                        "type": "integer",
                        "description": "Employeeid. Id only - `premployee` is read-only or has no code key.",
                        "x-idonly": true
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "ordered": {
                        "type": "integer",
                        "description": "1 marks pre-ordered hours - time sold in advance rather than actual worked time."
                    },
                    "techname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Name of the technician who worked the time, as entered."
                    },
                    "hours": {
                        "type": "string",
                        "description": "Quantity, 2 decimal places, as a string. Stored as `decimal(2dp)`.",
                        "x-decimals": 2,
                        "x-qty": true
                    },
                    "startdatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the work started."
                    },
                    "enddatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the work ended."
                    },
                    "rate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "totalprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "totalcost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "worksubtypeid": {
                        "type": "integer",
                        "description": "Worksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date",
                        "description": "When the record was created."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "internal_comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Internal_comment. Stored as `text`, no practical length limit."
                    },
                    "costrate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "status": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "0 = zero-hour placeholder (never bills), 1 = ready to bill (set automatically the moment hours are non-zero - there is no approval step), 2 = billed (an order line exists for it; the entry refuses PATCH and DELETE). Derived, never accepted as input."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Orderid. Id only.",
                        "x-idonly": true
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the billable rate is stated in."
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "assetidlastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the assigned asset last changed on the time entry."
                    },
                    "baserate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(10,4)`.",
                        "x-decimals": 4
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "description": "Prpaytypeid. Id only.",
                        "x-idonly": true
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefApbills": {
                "type": "object",
                "description": "Vendor bills. Lines go in the same request - see Conventions on nested writes.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "invoicenumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The vendor’s own invoice number. Required and never generated - it is how duplicate bills are spotted."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "complete": {
                        "type": "integer",
                        "description": "1 when the bill is fully paid.",
                        "readOnly": true
                    },
                    "paynone": {
                        "type": "integer",
                        "description": "1 puts the bill on payment hold; payment runs set to skip held bills exclude it."
                    },
                    "total": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Bill description."
                    },
                    "dateofinvoice": {
                        "type": "string",
                        "format": "date",
                        "description": "Date on the vendor’s invoice - the accounting date the bill posts under."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "discountamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "discountdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Last date the early-payment discount applies."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Comment. Stored as `text`, no practical length limit."
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Module that raised the bill: 1 = entered in AP."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "approved_paydate": {
                        "type": "string",
                        "format": "date",
                        "description": "Pay date approved in the pre-approval workflow."
                    },
                    "preapproved_userid": {
                        "type": "integer",
                        "description": "User who pre-approved the bill for payment.",
                        "readOnly": true
                    },
                    "preapproved_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `preapproved_userid`, not both unless they agree."
                    },
                    "preapproved_status": {
                        "type": "integer",
                        "description": "Pre-approval workflow status: 0 = pending, 1 = approved."
                    },
                    "preapproved_checkacctid": {
                        "type": "integer",
                        "description": "Checking account chosen for the bill during pre-approval."
                    },
                    "preapproved_checkacct": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `name` of the referenced checkaccounts, instead of the id. Send this or `preapproved_checkacctid`, not both unless they agree."
                    },
                    "preapproved_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(15,6)`.",
                        "x-decimals": 6
                    },
                    "preapproved_interest": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(15,6)`.",
                        "x-decimals": 6
                    },
                    "old_id": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Bill id in the system this record was imported from.",
                        "readOnly": true
                    },
                    "ccpurchase": {
                        "type": "integer",
                        "description": "1 when the bill is a credit-card purchase (shown on the CC purchases tab)."
                    },
                    "apglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `apglaccount`."
                    },
                    "apglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `apglaccountid`, not both unless they agree."
                    },
                    "chargeback": {
                        "type": "integer",
                        "description": "1 when the bill is charged back to another party."
                    },
                    "recurring": {
                        "type": "integer",
                        "description": "1 when the bill is a recurring template that generates future bills."
                    },
                    "payplan_dayofmonth": {
                        "type": "integer",
                        "description": "Day of the month the recurring bill generates on."
                    },
                    "payplan_days": {
                        "type": "integer",
                        "description": "Interval in days between generated bills, when not monthly."
                    },
                    "payplan_next": {
                        "type": "string",
                        "format": "date",
                        "description": "Next date the recurring bill generates."
                    },
                    "payplan_numtimes": {
                        "type": "integer",
                        "description": "Remaining number of bills the recurrence will generate; -1 repeats indefinitely."
                    },
                    "isretainer": {
                        "type": "integer",
                        "description": "1 when the bill holds retainage withheld from another bill."
                    },
                    "retainer_apbillid": {
                        "type": "integer",
                        "description": "Retainer apbillid. Id only.",
                        "x-idonly": true
                    },
                    "drawid": {
                        "type": "integer",
                        "description": "Drawid. Id only.",
                        "x-idonly": true
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the bill is payable in."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "alternate_paytoname": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Pay To name printed on the check when it differs from the vendor name."
                    },
                    "non_negotiable": {
                        "type": "integer",
                        "description": "1 prints the payment check as Non-Negotiable, recording a payment made outside AP."
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "frommanual": {
                        "type": "integer",
                        "description": "1 when the bill came from Manual Checks entry."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "altglpostdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Alternate GL posting date, when the bill posts to a different period than the invoice date."
                    },
                    "frompayroll": {
                        "type": "integer",
                        "description": "1 when the bill was generated by payroll (tax and deduction remittances)."
                    },
                    "highpriority": {
                        "type": "integer",
                        "description": "1 marks the bill High Priority in payment runs."
                    },
                    "invoicetermsid": {
                        "type": "integer",
                        "description": "Reference to `invoiceterms`, by id. Write either this or `invoiceterms`."
                    },
                    "invoiceterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `verbal` of the referenced invoiceterms, instead of the id. Send this or `invoicetermsid`, not both unless they agree."
                    },
                    "prepaid": {
                        "type": "integer",
                        "description": "Prepaid. Id only.",
                        "x-idonly": true
                    },
                    "invpodepositid": {
                        "type": "integer",
                        "description": "Purchase-order deposit this bill settles. Read-only: the link is made by NolaPro's own PO deposit flow, and no /invpodeposits resource exists to name or supply the id.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefApbilllines": {
                "type": "object",
                "description": "Lines on a vendor bill. Normally sent nested inside the bill.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "apbillid": {
                        "type": "integer",
                        "description": "Apbillid. Id only.",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "invreceiveid": {
                        "type": "integer",
                        "description": "Invreceiveid. Id only.",
                        "x-idonly": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "What the expense line covers."
                    },
                    "isretainer": {
                        "type": "integer",
                        "description": "1 when the line is withheld retainage."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefBankdeposits": {
                "type": "object",
                "description": "Deposits into a bank account.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "cashtotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "checktotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "othertotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "cashout": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "depositdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date of the bank deposit - the accounting date it posts under."
                    },
                    "checkaccountid": {
                        "type": "integer",
                        "description": "Checking account the deposit goes into."
                    },
                    "checkaccount": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `name` of the referenced checkaccounts, instead of the id. Send this or `checkaccountid`, not both unless they agree."
                    },
                    "onbankstatement": {
                        "type": "integer",
                        "description": "1 once the deposit has been matched to a bank statement.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "bankstatement_enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "End date of the bank statement the deposit was reconciled under. Maintained by bank reconciliation.",
                        "readOnly": true
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "depositdescription": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Description printed on the deposit slip."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency of the deposit."
                    },
                    "ccdeposit": {
                        "type": "integer",
                        "description": "1 when the deposit records credit-card settlement funds rather than checks and cash."
                    },
                    "ardailycloseid": {
                        "type": "integer",
                        "description": "Ardailycloseid. Id only.",
                        "x-idonly": true
                    },
                    "bankstatement_cleardate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the deposit cleared the bank. Maintained by bank reconciliation.",
                        "readOnly": true
                    },
                    "cancelvoucherid": {
                        "type": "integer",
                        "description": "Cancelvoucherid. Id only."
                    },
                    "cancelvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `cancelvoucherid`, not both unless they agree."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefJobs": {
                "type": "object",
                "description": "Construction jobs. Costs and revenue can be tracked against one.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "jobcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Short code identifying the job."
                    },
                    "jobname": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the job."
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "City of the job site."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "State of the job site."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Postal code."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "status": {
                        "type": "string",
                        "description": "Status. Labels are `Job_model::$statuses`; stored as an int and never exposed or accepted as one (D35).",
                        "enum": [
                            "active",
                            "inactive"
                        ]
                    },
                    "productionmanager_userid": {
                        "type": "integer",
                        "description": "NolaPro user assigned as the job’s production manager."
                    },
                    "productionmanager_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `productionmanager_userid`, not both unless they agree."
                    },
                    "owner_companyid": {
                        "type": "integer",
                        "description": "Owner companyid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "site_manager_userid": {
                        "type": "integer",
                        "description": "NolaPro user assigned as the job’s site manager."
                    },
                    "site_manager_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `site_manager_userid`, not both unless they agree."
                    },
                    "isconstructionjob": {
                        "type": "integer",
                        "description": "1 marks a construction job - construction budget reports and the bank, lien, and prelim fields apply."
                    },
                    "bankname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Bank funding the construction loan."
                    },
                    "bankcontact_name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Contact at the funding bank."
                    },
                    "bankcontact_email": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email of the funding bank contact."
                    },
                    "bankinspector_name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Bank inspector who signs off draws."
                    },
                    "bankinspector_email": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Email of the bank inspector."
                    },
                    "msproject_jobname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Job name as it appears in the imported Microsoft Project plan."
                    },
                    "region": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Region the job belongs to."
                    },
                    "isexternalclient": {
                        "type": "integer",
                        "description": "1 when the job’s owner is an external client rather than one of the install’s own companies."
                    },
                    "sitecode": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Short code of the job site."
                    },
                    "riskinsurance_underwriter": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Risk Insurance Underwriter for the job."
                    },
                    "riskinsurance_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "riskinsurance_expiration": {
                        "type": "string",
                        "format": "date",
                        "description": "When the job’s risk insurance expires."
                    },
                    "siteid": {
                        "type": "integer",
                        "description": "Siteid. Id only.",
                        "x-idonly": true
                    },
                    "projectid": {
                        "type": "integer",
                        "description": "Row id in the `project` table the job belongs to. That table has no API endpoint (it is used only by tenant-specific customizations), so this reference is id-only.",
                        "x-idonly": true
                    },
                    "architectvendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `architectvendor`."
                    },
                    "architectvendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `architectvendorid`, not both unless they agree."
                    },
                    "clientprojectnumber": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The client’s own project number for the job."
                    },
                    "contractdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the contract was signed."
                    },
                    "inactive": {
                        "type": "integer",
                        "description": "1 hides the job from active job lists."
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "apn": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "APN - Assessor’s Parcel Number of the job site."
                    },
                    "closed": {
                        "type": "boolean",
                        "description": "The relationship has ended. Not the same as cancelled."
                    },
                    "closeddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the job was closed."
                    },
                    "closeduserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `closeduser`."
                    },
                    "closeduser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `closeduserid`, not both unless they agree."
                    },
                    "contactname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Job site contact."
                    },
                    "contacttitle": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Title of the job site contact."
                    },
                    "contractnumber": {
                        "type": "string",
                        "maxLength": 24,
                        "description": "Contract number for the job."
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the job site."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "defaultshipvia": {
                        "type": "integer",
                        "description": "Default shipping method for materials going to the job."
                    },
                    "estpurchase": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "jobtype": {
                        "type": "integer",
                        "description": "Job type, from the company’s job types list."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "latitude": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "longitude": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "numjobyears": {
                        "type": "integer",
                        "description": "How many years the job spans (Num Job Years)."
                    },
                    "permitcontact": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Contact for building permits."
                    },
                    "ponum": {
                        "type": "string",
                        "maxLength": 24,
                        "description": "PO# - the customer’s purchase order covering the job."
                    },
                    "prelimable": {
                        "type": "boolean",
                        "description": "True when the job qualifies for a preliminary lien notice (Job Prelimable)."
                    },
                    "prelimamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "prelimcounty": {
                        "type": "string",
                        "maxLength": 24,
                        "description": "County where the preliminary notice is recorded."
                    },
                    "prelimcreditlimit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "prelimdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the preliminary notice was filed."
                    },
                    "prelimestimate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "prelimnotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Prelimnotes. Stored as `text`, no practical length limit."
                    },
                    "prelimstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Status text of the preliminary notice."
                    },
                    "productionsalesmanid": {
                        "type": "integer",
                        "description": "Reference to `salesmen`, by id. Write either this or `productionsalesman`."
                    },
                    "productionsalesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `productionsalesmanid`, not both unless they agree."
                    },
                    "sitesalesmanid": {
                        "type": "integer",
                        "description": "Reference to `salesmen`, by id. Write either this or `sitesalesman`."
                    },
                    "sitesalesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `sitesalesmanid`, not both unless they agree."
                    },
                    "taskstatusid": {
                        "type": "integer",
                        "description": "Reference to `taskstatuses`, by id. Write either this or `taskstatus`."
                    },
                    "taskstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taskstatuses, instead of the id. Send this or `taskstatusid`, not both unless they agree."
                    },
                    "zlienid": {
                        "type": "integer",
                        "description": "Zlienid. Id only.",
                        "x-idonly": true
                    },
                    "zlienready": {
                        "type": "boolean",
                        "description": "True when the job is ready to send to the lien service (Zlien Ready)."
                    },
                    "deferredvoucherid": {
                        "type": "integer",
                        "description": "Deferredvoucherid. Id only."
                    },
                    "deferredvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `deferredvoucherid`, not both unless they agree."
                    },
                    "lieneddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date a lien was filed on the job."
                    },
                    "prelimfirstinvoicedate": {
                        "type": "string",
                        "format": "date",
                        "description": "First invoice date used to compute the preliminary notice deadline."
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Reference to `taxexempts`, by id. Write either this or `taxexempt`."
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `taxexemptid`, not both unless they agree."
                    },
                    "unincorporated": {
                        "type": "integer",
                        "description": "1 when the job site is in an unincorporated area, so no city sales tax applies."
                    },
                    "zlienhirepartyrole": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Role of the party that hired you, as sent to the lien service (e.g. Subcontractor)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemvendors": {
                "type": "object",
                "description": "Which vendors supply an item, and at what cost.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "vordernumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The vendor’s own catalog/order number for the item, printed on POs."
                    },
                    "vitemunitnameid": {
                        "type": "integer",
                        "description": "Reference to `unitnames`, by id. Write either this or `vitemunitname`."
                    },
                    "vitemunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `vitemunitnameid`, not both unless they agree."
                    },
                    "vitemconversion": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,6)`.",
                        "x-decimals": 6
                    },
                    "vitemcost1": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "vitemqty1": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "vitemcost2": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "vitemqty2": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "vitemcost3": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "vitemqty3": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "vitemcost4": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "mfg": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Manufacturer name for this vendor’s version of the item."
                    },
                    "is_default": {
                        "type": "boolean",
                        "description": "1 when this is the item’s default vendor."
                    },
                    "freightpercent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "leadtimedays": {
                        "type": "integer",
                        "description": "Lead time in days for this vendor to supply the item."
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "upc": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Universal Product Code."
                    },
                    "bestbuy": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemoptions": {
                "type": "object",
                "description": "Options on a configurable item.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "itemoptiongroupid": {
                        "type": "integer",
                        "description": "Itemoptiongroupid. Id only.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "optioncode": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Short code of the option, shown after its name in pickers."
                    },
                    "price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,6)`.",
                        "x-decimals": 6
                    },
                    "cost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,6)`.",
                        "x-decimals": 6
                    },
                    "minqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "maxqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "mainind": {
                        "type": "integer",
                        "description": "0 when the option quantity follows the main item quantity, 1 when it is independent (the screen asks Dependent On Main Item Qty)."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Option name shown to the buyer."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "priceunitnameid": {
                        "type": "integer",
                        "description": "Priceunitnameid. Id only."
                    },
                    "priceunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `priceunitnameid`, not both unless they agree."
                    },
                    "salesunitnameid": {
                        "type": "integer",
                        "description": "Reference to `unitnames`, by id. Write either this or `salesunitname`."
                    },
                    "salesunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `salesunitnameid`, not both unless they agree."
                    },
                    "saleunitperpriceunit": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "lbsperpriceunit": {
                        "type": "string",
                        "description": "Numeric string. Not money - do not apply currency rounding.",
                        "x-number": true
                    },
                    "defaultvalue": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,6)`.",
                        "x-decimals": 6
                    },
                    "defaultoption": {
                        "type": "integer",
                        "description": "1 preselects this option in its group."
                    },
                    "displayorder": {
                        "type": "integer",
                        "description": "Position of the option within its group."
                    },
                    "taxable": {
                        "type": "integer",
                        "description": "Whether this line is taxed."
                    },
                    "salesglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `salesglaccount`."
                    },
                    "salesglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `salesglaccountid`, not both unless they agree."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemoptiongroups": {
                "type": "object",
                "description": "Groups that item options belong to.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the option group shown above its choices."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "optiontype": {
                        "type": "string",
                        "description": "How the group renders: radio, checkbox, or select.",
                        "x-unbounded": true
                    },
                    "allowblank": {
                        "type": "integer",
                        "description": "1 allows leaving the group unselected."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "default": {
                        "type": "boolean",
                        "description": "Default choice for the group."
                    },
                    "invoiceprinthidezerototals": {
                        "type": "boolean",
                        "description": "1 hides zero-total option lines when printing invoices."
                    },
                    "invoiceprintmode": {
                        "type": "boolean",
                        "description": "How chosen options print on invoices: 0 = each option on its own line, 1 = grouped into a subtotal."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefContactnames": {
                "type": "object",
                "description": "Named contacts on a customer or ship-to.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "tablename": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Which table the contact belongs to (customer, vendor, shipto)."
                    },
                    "tablerecordid": {
                        "type": "integer",
                        "description": "Tablerecordid. Id only.",
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "firstname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Contact first name."
                    },
                    "lastname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Contact last name."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "authorizedbuyer": {
                        "type": "boolean",
                        "description": "True when the contact is an authorized buyer for the account."
                    },
                    "taskstatusid": {
                        "type": "integer",
                        "description": "Reference to `taskstatuses`, by id. Write either this or `taskstatus`."
                    },
                    "taskstatus": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taskstatuses, instead of the id. Send this or `taskstatusid`, not both unless they agree."
                    },
                    "inactive": {
                        "type": "integer",
                        "description": "1 hides the contact from pickers."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefPricelevels": {
                "type": "object",
                "description": "Customer price tiers.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Name of the price level."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "markdownpercent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "markdownpricelevelid": {
                        "type": "integer",
                        "description": "Markdownpricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefPrpaytypes": {
                "type": "object",
                "description": "Payroll pay types.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 6,
                        "description": "Short name of the pay type."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 40,
                        "description": "Description of the pay type."
                    },
                    "multiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "vacation": {
                        "type": "integer",
                        "description": "1 when hours under this pay type draw down vacation accrual."
                    },
                    "sick": {
                        "type": "integer",
                        "description": "1 when hours under this pay type draw down sick accrual."
                    },
                    "exclude_from_hours_worked": {
                        "type": "integer",
                        "description": "1 excludes hours under this pay type from hours-worked totals (e.g. bonuses)."
                    },
                    "ar": {
                        "type": "boolean",
                        "description": "True offers the pay type when billing time in AR and service orders."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "pr": {
                        "type": "boolean",
                        "description": "True offers the pay type in payroll time entry."
                    },
                    "specialpurpose": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "Marker for system-managed pay types (e.g. CTE/CTU for comp-time earned/used); empty for ordinary pay types."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefProducttypetaxes": {
                "type": "object",
                "description": "Product tax classification.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the product-type tax."
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "states": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "States. Stored as `text`, no practical length limit."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefDiscounts": {
                "type": "object",
                "description": "Discount definitions.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Name of the discount."
                    },
                    "discountpercent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCoupons": {
                "type": "object",
                "description": "Coupon codes.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "coupon_code": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Code the customer enters to apply the coupon."
                    },
                    "percent_discount": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "dollars_discount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Description of the coupon."
                    },
                    "expirationdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the coupon stops working."
                    },
                    "maxdollars": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefLeases": {
                "type": "object",
                "description": "Lease agreements.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "unitid": {
                        "type": "integer",
                        "description": "Unitid. Id only.",
                        "x-idonly": true
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "userid": {
                        "type": "integer",
                        "description": "Userid. Id only."
                    },
                    "user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `userid`, not both unless they agree."
                    },
                    "rentperiod": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "Rent Period: W = weekly, SM = semi-monthly, M = monthly, S = semester, SY = semi-yearly, AY = academic year, Y = yearly."
                    },
                    "cotenant": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Co-tenant named on the lease."
                    },
                    "cotenantemail": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Email of the co-tenant."
                    },
                    "begindate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the lease begins."
                    },
                    "enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the lease ends."
                    },
                    "moveindate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the tenant moves in."
                    },
                    "firstinvoicemonths": {
                        "type": "integer",
                        "description": "Months before the move-in date that the first invoice comes due; copied from the building default."
                    },
                    "origenddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Original end date before any renewal or extension."
                    },
                    "rentamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "petrent": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "lawncare": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "revenueglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `revenueglaccount`."
                    },
                    "revenueglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `revenueglaccountid`, not both unless they agree."
                    },
                    "petrentglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `petrentglaccount`."
                    },
                    "petrentglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `petrentglaccountid`, not both unless they agree."
                    },
                    "lawncareglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `lawncareglaccount`."
                    },
                    "lawncareglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `lawncareglaccountid`, not both unless they agree."
                    },
                    "deferredrevenueglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `deferredrevenueglaccount`."
                    },
                    "deferredrevenueglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `deferredrevenueglaccountid`, not both unless they agree."
                    },
                    "numpayments": {
                        "type": "integer",
                        "description": "Number of rent payments over the lease term, derived from the rent period (e.g. 12 for monthly)."
                    },
                    "depositamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "depositcredit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "depositreturned": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "depositreturnedinvoiceid": {
                        "type": "integer",
                        "description": "Invoice the returned deposit was credited on. Write either this or `depositreturnedinvoice`."
                    },
                    "depositreturnedinvoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Invoice NUMBER (`arinvoice.invoicenumber`) instead of the id. The sibling of `depositreturnedinvoiceid`."
                    },
                    "depositkeptvoucherid": {
                        "type": "integer",
                        "description": "Depositkeptvoucherid. Id only."
                    },
                    "depositkeptvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `depositkeptvoucherid`, not both unless they agree."
                    },
                    "depositglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `depositglaccount`."
                    },
                    "depositglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `depositglaccountid`, not both unless they agree."
                    },
                    "overagecap": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "latefee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "transferfee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "reservationfee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "reservationfeeglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `reservationfeeglaccount`."
                    },
                    "reservationfeeglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `reservationfeeglaccountid`, not both unless they agree."
                    },
                    "petdeposit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "petdepositcredit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "petdepositglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `petdepositglaccount`."
                    },
                    "petdepositglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `petdepositglaccountid`, not both unless they agree."
                    },
                    "petdepositreturned": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "proratedamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "prorateddays": {
                        "type": "integer",
                        "description": "Days of prorated rent billed for a partial first period."
                    },
                    "proratedtotaldays": {
                        "type": "integer",
                        "description": "Total days in the period the proration was computed against."
                    },
                    "paymentplan": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Paymentplan. Stored as `text`, no practical length limit."
                    },
                    "leaseended": {
                        "type": "integer",
                        "description": "1 once the lease has ended."
                    },
                    "leaseendeddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the lease actually ended."
                    },
                    "leaseendeduserid": {
                        "type": "integer",
                        "description": "Reference to `genusers`, by id. Write either this or `leaseendeduser`."
                    },
                    "leaseendeduser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `leaseendeduserid`, not both unless they agree."
                    },
                    "origleaseid": {
                        "type": "integer",
                        "description": "Origleaseid. Id only.",
                        "x-idonly": true
                    },
                    "renewed": {
                        "type": "integer",
                        "description": "1 when the lease was renewed into a newer lease."
                    },
                    "transferred": {
                        "type": "integer",
                        "description": "1 when the lease was transferred to another unit or tenant."
                    },
                    "transferredunitid": {
                        "type": "integer",
                        "description": "Transferredunitid. Id only.",
                        "x-idonly": true
                    },
                    "autobill": {
                        "type": "integer",
                        "description": "1 generates rent invoices automatically each period (Auto Bill)."
                    },
                    "leasecode": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Short code identifying the lease."
                    },
                    "signed": {
                        "type": "integer",
                        "description": "1 once the signed lease is on file; unsigned leases are flagged on lease lists."
                    },
                    "prepaymentamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "prepaymentdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the prepayment (e.g. deposit or first rent) was received."
                    },
                    "cotenant2": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Second co-tenant named on the lease."
                    },
                    "cotenant2email": {
                        "type": "string",
                        "maxLength": 200,
                        "description": "Email of the second co-tenant."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefStages": {
                "type": "object",
                "description": "Pipeline stages.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "stagetypeid": {
                        "type": "integer",
                        "description": "Stagetypeid. Id only.",
                        "x-idonly": true
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Name of the stage."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Short code of the stage."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "autotrigger": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Action code that automatically advances a document into this stage (the Automatic Trigger on stage setup)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order. Lower sorts first."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefWorksubtypes": {
                "type": "object",
                "description": "Subtypes under a work type.",
                "properties": {
                    "id_worksubtype": {
                        "type": "integer",
                        "description": "Primary key of the work subtype (this table is keyed `id_worksubtype`, not `id`).",
                        "readOnly": true
                    },
                    "id_worktype": {
                        "type": "integer",
                        "description": "The work type this subtype belongs to."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Name of the work subtype."
                    },
                    "purpose": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "What the work subtype is used for."
                    },
                    "num_parts": {
                        "type": "integer",
                        "description": "Number of parts the work applies to (multi-part forms)."
                    },
                    "vended": {
                        "type": "integer",
                        "description": "Non-zero when the work is vended - purchased outside rather than produced in-house."
                    },
                    "createdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the change happened, not when we sent it. A retry two hours later still carries the original time."
                    },
                    "id_user_create": {
                        "type": "integer",
                        "description": "User who created the record.",
                        "readOnly": true
                    },
                    "lastrevisedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was last revised.",
                        "readOnly": true
                    },
                    "id_user_revise": {
                        "type": "integer",
                        "description": "User who last revised the record.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCcterminals": {
                "type": "object",
                "description": "Physical card terminals.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Short code identifying the terminal wherever one is picked (POS, order payment)."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Free-form name of the terminal."
                    },
                    "ip": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "Network address the payment middleware uses to reach the terminal device."
                    },
                    "port": {
                        "type": "integer",
                        "description": "Port the payment middleware uses to reach the terminal device."
                    },
                    "checkedout": {
                        "type": "boolean",
                        "description": "True while a user has the terminal checked out for exclusive use. Managed by the check-out/check-in workflow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "checkedoutuserid": {
                        "type": "integer",
                        "description": "The user who currently has the terminal checked out. Managed by the check-out workflow, so read-only.",
                        "readOnly": true
                    },
                    "checkedoutuser": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the user who currently has the terminal checked out.",
                        "readOnly": true
                    },
                    "checkacctid": {
                        "type": "integer",
                        "description": "Reference to `checkaccounts`, by id. Write either this or `checkacct`."
                    },
                    "checkacct": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `name` of the referenced checkaccounts, instead of the id. Send this or `checkacctid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "ccaccountid": {
                        "type": "integer",
                        "description": "Reference to `ccaccounts`, by id. Write either this or `ccaccount`."
                    },
                    "ccaccount": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced ccaccounts, instead of the id. Send this or `ccaccountid`, not both unless they agree."
                    },
                    "settings": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Terminal behavior options as a JSON object (timeouts, whether the customer name is sent to the device). Edited on the terminal setup screen. Stored as `mediumtext`, no practical length limit."
                    },
                    "ccterminaltype": {
                        "type": "integer",
                        "description": "What drives the terminal: 0 = a local device reached through the NolaPro payment middleware, 2 = a PaidYET terminal."
                    },
                    "meta": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Device metadata synced from the payment provider (for PaidYET, the terminal record it reports). Maintained by the sync, so it cannot be written through the API. Stored as `mediumtext`, no practical length limit.",
                        "readOnly": true
                    },
                    "activeccterminallogid": {
                        "type": "integer",
                        "description": "The in-flight terminal transaction (ccterminallog id) while a payment is processing; 0 when idle. Managed by the payment flow, so it cannot be written through the API.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItempricespecialdetails": {
                "type": "object",
                "description": "Special pricing rows for an item.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "itempricespecialid": {
                        "type": "integer",
                        "description": "Itempricespecialid. Id only.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "begindate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the special price starts."
                    },
                    "enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the special price ends."
                    },
                    "margin": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "mincost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(18,6)`.",
                        "x-decimals": 6
                    },
                    "notes": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Notes on the special price."
                    },
                    "period": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Rental period the special price applies to: D = daily, W = weekly, M = monthly. Empty for non-rental pricing."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefVendororderfroms": {
                "type": "object",
                "description": "Alternate addresses a vendor is ordered from.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "companyname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Company name on this Order From address."
                    },
                    "contactname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Ordering contact at this address."
                    },
                    "address": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Address. Stored as `text`, no practical length limit."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the address."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "country": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Country of the address."
                    },
                    "phone": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Phone number of the ordering contact."
                    },
                    "fax": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Fax number purchase orders are sent to."
                    },
                    "email": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Email address."
                    },
                    "mailstop": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Mail stop line printed with the address."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefRmareturns": {
                "type": "object",
                "description": "Returned lines against an RMA.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "rma_arorderid": {
                        "type": "integer",
                        "description": "Rma arorderid. Id only.",
                        "x-idonly": true
                    },
                    "return_date": {
                        "type": "string",
                        "format": "date",
                        "description": "Date the goods were returned."
                    },
                    "taxid": {
                        "type": "integer",
                        "description": "Taxid. Id only.",
                        "x-idonly": true
                    },
                    "taxcredit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "taxid2": {
                        "type": "integer",
                        "description": "Second sales tax applied to the return."
                    },
                    "taxcredit2": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "taxid3": {
                        "type": "integer",
                        "description": "Third sales tax applied to the return."
                    },
                    "taxcredit3": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "shipping_credit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "restock_fee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "total_credit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "invoiceid": {
                        "type": "integer",
                        "description": "Invoiceid. Id only."
                    },
                    "invoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `invoiceid`, not both unless they agree."
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "new_orderid": {
                        "type": "integer",
                        "description": "New orderid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCctransactions": {
                "type": "object",
                "description": "**Read-only.** Gateway transaction records. Card data is never returned.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "b2buserid": {
                        "type": "integer",
                        "description": "The B2B portal login that submitted the payment, when it came through the portal; 0 for payments taken inside NolaPro.",
                        "x-idonly": true
                    },
                    "ccaccountid": {
                        "type": "integer",
                        "description": "The gateway account (`ccaccounts`) the transaction ran through.",
                        "x-idonly": true
                    },
                    "referid": {
                        "type": "integer",
                        "description": "Row id in `refertable` of the document the payment applies to.",
                        "x-idonly": true
                    },
                    "refertable": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Which table `referid` points at: `arinvoice` for invoice payments, `gltransvoucher` for deposit transactions."
                    },
                    "transtype": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Transaction type sent to the gateway: S = sale, A = authorization, D = prior-authorization capture, F = capture only, C = credit, V = void."
                    },
                    "cardtype": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Card brand as the gateway reported it (Visa, MasterCard, American Express, Discover)."
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Total amount sent to the gateway. Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "nontaxable": {
                        "type": "string",
                        "x-money": true,
                        "description": "Non-taxable portion of the amount, sent for level-2 card data. Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "shipping": {
                        "type": "string",
                        "x-money": true,
                        "description": "Shipping portion of the amount, sent for level-2 card data. Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "tax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Tax portion of the amount, sent for level-2 card data. Stored as `decimal(12,4)`.",
                        "x-decimals": 4
                    },
                    "transid": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The gateway’s reference number for this transaction."
                    },
                    "optionalid": {
                        "type": "string",
                        "maxLength": 80,
                        "description": "Gateway-specific secondary reference: the batch reference number for middleware transactions, the saved payment-method id for appointment charges."
                    },
                    "resultcode": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Outcome: A = approved, D = denied, E = error."
                    },
                    "resultreasoncode": {
                        "type": "integer",
                        "description": "Numeric reason code the gateway returned alongside `resultcode`."
                    },
                    "resultreasontext": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Human-readable response text from the gateway."
                    },
                    "authcode": {
                        "type": "string",
                        "maxLength": 25,
                        "description": "Authorization code the processor returned for an approved transaction - the code printed on receipts."
                    },
                    "avscode": {
                        "type": "string",
                        "maxLength": 2,
                        "description": "Address Verification System result code from the gateway."
                    },
                    "customerip": {
                        "type": "string",
                        "maxLength": 25,
                        "description": "IP address the payment was submitted from, recorded for card-not-present transactions."
                    },
                    "customerconfirmation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Confirmation number generated for the customer’s receipt."
                    },
                    "authopen": {
                        "type": "integer",
                        "description": "1 while an authorization (`transtype` A) has not been captured; cleared when the capture or void arrives."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "authtransid": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Gateway transaction id of the original authorization a capture or void applies to."
                    },
                    "authorize_extra": {
                        "type": "integer",
                        "description": "Extra percentage added when authorizing, from the account’s Extra Auth Percent option (tip headroom); 0 otherwise."
                    },
                    "userdata": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Free-form gateway passthrough data. Rarely populated."
                    },
                    "billingaddress": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Billing street address sent to the gateway for address verification."
                    },
                    "billingcity": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Billing city sent to the gateway for address verification."
                    },
                    "billingstate": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Billing state sent to the gateway for address verification."
                    },
                    "billingzip": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Billing ZIP sent to the gateway for address verification."
                    },
                    "cardpresent": {
                        "type": "integer",
                        "description": "1 when the card was physically present (swiped or tapped); 0 for keyed and online payments."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency code of the charge."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    }
                }
            },
            "RefCcpurchases": {
                "type": "object",
                "description": "**Read-only.** Card purchase records.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "ccvendorid": {
                        "type": "integer",
                        "description": "Ccvendorid. Id only.",
                        "x-idonly": true
                    },
                    "purchasedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date of the credit-card purchase."
                    },
                    "who": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Who made the purchase."
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "purpose": {
                        "type": "string",
                        "maxLength": 250,
                        "description": "What the purchase was for."
                    },
                    "apbillid": {
                        "type": "integer",
                        "description": "Apbillid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "purchasefrom": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Merchant the purchase was made from."
                    },
                    "invpoid": {
                        "type": "integer",
                        "description": "Invpoid. Id only.",
                        "x-idonly": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only.",
                        "x-idonly": true
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency of the purchase."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    }
                }
            },
            "RefExtusers": {
                "type": "object",
                "description": "**Read-only and minimal.** External identities. Credentials are never returned.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Display name of the external user."
                    },
                    "customer": {
                        "type": "integer",
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "vendor": {
                        "type": "integer",
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "stylesheetid": {
                        "type": "integer",
                        "description": "Stylesheetid. Id only.",
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "deflanguageid": {
                        "type": "integer",
                        "description": "Deflanguageid. Id only.",
                        "x-idonly": true
                    },
                    "fullname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Generated by the database. Read-only."
                    }
                }
            },
            "RefInvreceives": {
                "type": "object",
                "description": "What was received against a purchase order.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "recsource": {
                        "type": "integer",
                        "description": "Where the receipt came from: 0 = received without a PO (direct item receipt), 1 = received against a purchase order."
                    },
                    "invpoid": {
                        "type": "integer",
                        "description": "Invpoid. Id only.",
                        "x-idonly": true
                    },
                    "receivedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the goods were received."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "itemqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "itemprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "itemqtyused": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "itemqtydamaged": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "conversion": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "track": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Carrier tracking number on the receipt."
                    },
                    "receiveunitnameid": {
                        "type": "integer",
                        "description": "Reference to `unitnames`, by id. Write either this or `receiveunitname`."
                    },
                    "receiveunitname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `receiveunitnameid`, not both unless they agree."
                    },
                    "passtoap": {
                        "type": "integer",
                        "description": "1 once the receipt is passed to AP for billing."
                    },
                    "apbillid": {
                        "type": "integer",
                        "description": "Apbillid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "invpodetailid": {
                        "type": "integer",
                        "description": "Invpodetailid. Id only.",
                        "x-idonly": true
                    },
                    "status": {
                        "type": "integer",
                        "description": "Receipt status; 0 = open."
                    },
                    "initials": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Initials of the person who received the goods."
                    },
                    "recnotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Recnotes. Stored as `text`, no practical length limit."
                    },
                    "itempriceqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the received cost is stated in."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "Voucherid. Id only."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `voucherid`, not both unless they agree."
                    },
                    "invreceivemainid": {
                        "type": "integer",
                        "description": "Invreceivemainid. Id only.",
                        "x-idonly": true
                    },
                    "accruedvoucherid": {
                        "type": "integer",
                        "description": "Accruedvoucherid. Id only."
                    },
                    "accruedvoucher": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `voucher` of the referenced gltransactions, instead of the id. Send this or `accruedvoucherid`, not both unless they agree."
                    },
                    "invpodetailinvglacct": {
                        "type": "integer",
                        "description": "Inventory GL account copied from the PO line being received."
                    },
                    "invpodetaillinetype": {
                        "type": "integer",
                        "description": "Line type copied from the PO line being received; 0 = standard product line."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefDraws": {
                "type": "object",
                "description": "Construction draws against a job.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the construction loan draw."
                    },
                    "status": {
                        "type": "integer",
                        "description": "Draw status code."
                    },
                    "drawtotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "drawdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date of the draw."
                    },
                    "retainage": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(6,2)`.",
                        "x-decimals": 2
                    },
                    "retainagetotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "invoiceid": {
                        "type": "integer",
                        "description": "Invoiceid. Id only."
                    },
                    "invoice": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `invoicenumber` of the referenced invoices, instead of the id. Send this or `invoiceid`, not both unless they agree."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "jobsondraw": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Jobsondraw. Stored as `text`, no practical length limit."
                    },
                    "changeorderadd": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "changeorderded": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefArdailycloses": {
                "type": "object",
                "description": "End-of-day close records.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "closedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Business date the daily close covers."
                    },
                    "actualcash": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "currencybreakdown": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Currencybreakdown. Stored as `text`, no practical length limit."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the close totals are stated in."
                    },
                    "actualchecks": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "cashdrawerfloat": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "depositeamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "actualcc": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "overshort": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "gl_cash": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "gl_cc": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "gl_checks": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "sys_cash": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "sys_cc": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "sys_checks": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItempricespecials": {
                "type": "object",
                "description": "Special pricing headers. The rows live in `itempricespecialdetails`.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "customerid": {
                        "type": "integer",
                        "description": "Reference to `customers`, by id. Write either this or `customer`."
                    },
                    "customer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced customer, instead of the id."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "begindate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the special pricing starts."
                    },
                    "enddate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the special pricing ends."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "static": {
                        "type": "boolean",
                        "description": "1 when the special is a static price rather than a discount off the regular price."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefSites": {
                "type": "object",
                "description": "Physical sites a job runs at.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "sitecode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Short code of the site."
                    },
                    "deal": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Deal. Stored as `text`, no practical length limit."
                    },
                    "owner": {
                        "type": "integer",
                        "description": "0 when the site is not owned by the associated company."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 250,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "estimate_groundbreak": {
                        "type": "string",
                        "format": "date",
                        "description": "Estimated groundbreaking date."
                    },
                    "status": {
                        "type": "integer",
                        "description": "Site status code."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "sitename": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the site."
                    },
                    "groundbreakingdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Actual groundbreaking date."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefUnits": {
                "type": "object",
                "description": "Rentable units in a building.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "buildingid": {
                        "type": "integer",
                        "description": "Buildingid. Id only.",
                        "x-idonly": true
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Unit name or number within the building."
                    },
                    "subname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Secondary name line for the unit (e.g. suite or room)."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "squarefeet": {
                        "type": "integer",
                        "description": "Floor area of the unit in square feet."
                    },
                    "rentamount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "rentperiod": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "Rent Period the unit is normally let by: W = weekly, SM = semi-monthly, M = monthly, S = semester, SY = semi-yearly, AY = academic year, Y = yearly."
                    },
                    "underrepair": {
                        "type": "integer",
                        "description": "1 while the unit is under repair and not rentable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "beds": {
                        "type": "integer",
                        "description": "Number of bedrooms."
                    },
                    "baths": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(4,1)`.",
                        "x-decimals": 1
                    },
                    "furnished": {
                        "type": "integer",
                        "description": "1 when the unit is furnished."
                    },
                    "den": {
                        "type": "integer",
                        "description": "1 when the unit has a den."
                    },
                    "fireplace": {
                        "type": "integer",
                        "description": "1 when the unit has a fireplace."
                    },
                    "carpet": {
                        "type": "integer",
                        "description": "1 when the unit is carpeted."
                    },
                    "drapes": {
                        "type": "integer",
                        "description": "1 when drapes are provided."
                    },
                    "airconditioning": {
                        "type": "integer",
                        "description": "1 when the unit has air conditioning."
                    },
                    "stove": {
                        "type": "integer",
                        "description": "1 when a stove is provided."
                    },
                    "washerdryerhookup": {
                        "type": "integer",
                        "description": "1 when the unit has washer/dryer hookups."
                    },
                    "washer": {
                        "type": "integer",
                        "description": "1 when a washer is provided."
                    },
                    "dryer": {
                        "type": "integer",
                        "description": "1 when a dryer is provided."
                    },
                    "refrigerator": {
                        "type": "integer",
                        "description": "1 when a refrigerator is provided."
                    },
                    "dishwasher": {
                        "type": "integer",
                        "description": "1 when a dishwasher is provided."
                    },
                    "disposal": {
                        "type": "integer",
                        "description": "1 when a garbage disposal is provided."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefCcterminallogs": {
                "type": "object",
                "description": "**Read-only.** Terminal activity log.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "ccterminalid": {
                        "type": "integer",
                        "description": "Ccterminalid. Id only.",
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "userid": {
                        "type": "integer",
                        "description": "Userid. Id only.",
                        "x-idonly": true
                    },
                    "resulttxt": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "Result text the terminal returned for the transaction."
                    },
                    "requestraw": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Requestraw. Stored as `text`, no practical length limit."
                    },
                    "replyraw": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Replyraw. Stored as `text`, no practical length limit."
                    },
                    "replyjson": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Replyjson. Stored as `text`, no practical length limit."
                    },
                    "cctransactionid": {
                        "type": "integer",
                        "description": "Cctransactionid. Id only.",
                        "x-idonly": true
                    },
                    "refid": {
                        "type": "integer",
                        "description": "Refid. Id only.",
                        "x-idonly": true
                    },
                    "reftable": {
                        "type": "string",
                        "maxLength": 64,
                        "description": "Table of the document the terminal payment was taken for."
                    },
                    "errorlog": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Errorlog. Stored as `text`, no practical length limit."
                    }
                }
            },
            "RefStagetypes": {
                "type": "object",
                "description": "**Read-only.** A static table rebuilt on every NolaPro update.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Short code of the stage type."
                    },
                    "tablename": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Table the stage applies to (which document type carries this stage)."
                    },
                    "title": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Stage title shown on screens."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "modaccess": {
                        "type": "string",
                        "maxLength": 150,
                        "description": "Module whose access rights govern the stage (ap, ar)."
                    },
                    "modbit": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Access bits string checked against the user’s module rights."
                    }
                }
            },
            "RefBuildings": {
                "type": "object",
                "description": "Buildings that rentable units belong to.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "code": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Short code identifying the building."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Building name."
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the building address."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the building address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "description": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Description. Stored as `text`, no practical length limit."
                    },
                    "managementfee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(6,2)`.",
                        "x-decimals": 2
                    },
                    "latefee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "transferfee": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "petrent": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "utilitiescharge": {
                        "type": "string",
                        "maxLength": 5,
                        "description": "How tenant utilities are billed: A = all usage, O = overage over the cap only."
                    },
                    "electricbasis": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "waterbasis": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "gasbasis": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "buildingtypeid": {
                        "type": "integer",
                        "description": "Buildingtypeid. Id only.",
                        "x-idonly": true
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "areaid": {
                        "type": "integer",
                        "description": "Reference to `areas`, by id. Write either this or `area`."
                    },
                    "area": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced areas, instead of the id. Send this or `areaid`, not both unless they agree."
                    },
                    "firstnotice": {
                        "type": "integer",
                        "description": "Days past due before the first late notice is sent."
                    },
                    "secondnotice": {
                        "type": "integer",
                        "description": "Days past due before the second late notice is sent."
                    },
                    "finalnotice": {
                        "type": "integer",
                        "description": "Days past due before the final late notice is sent."
                    },
                    "asleasetemplateid": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the lease agreement, 3-signer variant."
                    },
                    "asleasetemplateid2": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the lease agreement, 2-signer variant."
                    },
                    "asleasedocname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Document name given to the lease agreement when it is sent for e-signature."
                    },
                    "docexpirationdays": {
                        "type": "integer",
                        "description": "Days until an e-signature request for this building’s documents expires."
                    },
                    "asguarantordocname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Document name given to the guarantor agreement when it is sent for e-signature."
                    },
                    "asguarantortemplateid": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the guarantor agreement."
                    },
                    "aspetdocname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Document name given to the pet agreement when it is sent for e-signature."
                    },
                    "aspettemplateid": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the pet agreement."
                    },
                    "asterminationdocname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Document name given to the termination document when it is sent for e-signature."
                    },
                    "asterminationtemplateid": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the lease termination, 3-signer variant."
                    },
                    "asterminationtemplateid2": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the lease termination, 2-signer variant."
                    },
                    "firstinvoicemonths": {
                        "type": "integer",
                        "description": "Months before the move-in date that the first lease invoice comes due (0-11)."
                    },
                    "asamendmenttemplateid": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for a lease amendment."
                    },
                    "asamendmentdocname": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Document name given to the amendment when it is sent for e-signature."
                    },
                    "asleasetemplateid4": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "E-signature template id for the lease agreement, 4-signer variant."
                    },
                    "addressverified": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Hash of the address as it stood when it last passed the AvaTax/USPS address check; when it no longer matches the current address the address counts as unverified. Maintained by the verification flow, so it cannot be written through the API.",
                        "readOnly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefBuildingtypes": {
                "type": "object",
                "description": "Classification for buildings.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Name of the building type."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefEstquotepricelists": {
                "type": "object",
                "description": "Price lists used by Estimating quotes. The wider Estimating configuration surface (about 40 tables) is a module pass of its own and is not exposed here.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "stdsizeid": {
                        "type": "integer",
                        "description": "Stdsizeid. Id only.",
                        "x-idonly": true
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Price list name."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "maxinkside1": {
                        "type": "integer",
                        "description": "Most inks the price list covers on side 1."
                    },
                    "maxinkside2": {
                        "type": "integer",
                        "description": "Most inks the price list covers on side 2."
                    },
                    "trimchargepermpercut": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(8,2)`.",
                        "x-decimals": 2
                    },
                    "trimmincharge": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(8,2)`.",
                        "x-decimals": 2
                    },
                    "qtyperbox": {
                        "type": "string",
                        "description": "Quantity, 0 decimal places, as a string. Stored as `decimal(0dp)`.",
                        "x-decimals": 0,
                        "x-qty": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `blob`, no practical length limit."
                    },
                    "point2id": {
                        "type": "integer",
                        "description": "Point2id. Id only.",
                        "x-idonly": true
                    },
                    "covereach_blackinandout": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "covereach_coloroutblackin": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "covereach_colorinandout": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "costper_nocover": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "covereach_colorinblackout": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "noinkcharge": {
                        "type": "integer",
                        "description": "1 when ink is not charged separately on this price list."
                    },
                    "scrap_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "scrap_sheets_max": {
                        "type": "integer",
                        "description": "Maximum scrap sheets allowed into the price calculation."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "MeScope": {
                "type": "object",
                "description": "One scope on the token, and whether it can actually be used here.",
                "properties": {
                    "scope": {
                        "type": "string",
                        "maxLength": 60,
                        "readOnly": true,
                        "description": "The scope as granted.",
                        "x-example": "items:write"
                    },
                    "resource": {
                        "type": "string",
                        "maxLength": 40,
                        "readOnly": true,
                        "description": "Resource half of the scope.",
                        "x-example": "items"
                    },
                    "access": {
                        "type": "string",
                        "maxLength": 10,
                        "readOnly": true,
                        "description": "Access half: read, write or cancel.",
                        "x-example": "write"
                    },
                    "usable": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "False when the resource's feature is not active on this install. The scope is granted but every call using it returns 403.",
                        "x-example": true
                    },
                    "requires": {
                        "type": "string",
                        "maxLength": 40,
                        "readOnly": true,
                        "description": "The feature this scope needs. Present only when `usable` is false.",
                        "x-example": "inventory"
                    },
                    "reason": {
                        "type": "string",
                        "maxLength": 255,
                        "readOnly": true,
                        "description": "Why it cannot be used, in words. Present only when `usable` is false.",
                        "x-example": ""
                    }
                }
            },
            "Me": {
                "type": "object",
                "description": "What this token is and what it can do. **Needs no scope** - requiring one would be circular, and the moment you most need this endpoint is when a token is not working and you cannot tell why. The secret is never returned; only the prefix, which is what the token list displays.",
                "properties": {
                    "token": {
                        "type": "object",
                        "description": "The token itself.",
                        "properties": {
                            "prefix": {
                                "type": "string",
                                "maxLength": 16,
                                "readOnly": true,
                                "description": "Lookup prefix. Identifies the token without revealing it.",
                                "x-example": "np_v2_19f22986"
                            },
                            "label": {
                                "type": "string",
                                "maxLength": 100,
                                "readOnly": true,
                                "description": "What it was created for.",
                                "x-example": "Shopify sync (production)"
                            },
                            "expiredate": {
                                "type": "string",
                                "format": "date-time",
                                "readOnly": true,
                                "description": "Null when it does not expire."
                            },
                            "logenabled": {
                                "type": "boolean",
                                "readOnly": true,
                                "description": "Request logging is on for this token.",
                                "x-example": false
                            },
                            "lastuseddate": {
                                "type": "string",
                                "format": "date-time",
                                "readOnly": true,
                                "description": "Last time it authenticated."
                            }
                        }
                    },
                    "company": {
                        "type": "object",
                        "description": "The one company this token acts in.",
                        "properties": {
                            "id": {
                                "type": "integer",
                                "readOnly": true,
                                "description": "Company id.",
                                "x-example": 1
                            },
                            "name": {
                                "type": "string",
                                "maxLength": 100,
                                "readOnly": true,
                                "description": "Company name.",
                                "x-example": "Northwind Distributing"
                            }
                        }
                    },
                    "user": {
                        "type": "object",
                        "description": "The user it acts as.",
                        "properties": {
                            "id": {
                                "type": "integer",
                                "readOnly": true,
                                "description": "User id. This is what `entryuserid` will hold on records you create.",
                                "x-example": 1
                            },
                            "name": {
                                "type": "string",
                                "maxLength": 50,
                                "readOnly": true,
                                "description": "Login name.",
                                "x-example": "admin"
                            },
                            "firstname": {
                                "type": "string",
                                "maxLength": 50,
                                "readOnly": true,
                                "description": "First name.",
                                "x-example": "Alice"
                            },
                            "lastname": {
                                "type": "string",
                                "maxLength": 50,
                                "readOnly": true,
                                "description": "Last name.",
                                "x-example": "Admin"
                            },
                            "supervisor": {
                                "type": "boolean",
                                "readOnly": true,
                                "description": "Always true - it is checked on every request, so a token that gets this far has it.",
                                "x-example": true
                            }
                        }
                    },
                    "scopes": {
                        "type": "array",
                        "description": "Every scope on the token, sorted.",
                        "items": {
                            "$ref": "#/components/schemas/MeScope"
                        }
                    }
                }
            },
            "RefOrderlinesCreate": {
                "type": "object",
                "description": "A line on the order. `orderid` is not sent - the nesting says which order, and the id does not exist yet when you send the request. Derived amounts (`extended_price`, `products_tax`) are rejected: prices and quantities are the only inputs.",
                "properties": {
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position of this line on its document, starting at 1."
                    },
                    "qtyorder": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "qtyship": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "qtybill": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`."
                    },
                    "glaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced glaccount, instead of the id."
                    },
                    "taxflag": {
                        "type": "integer",
                        "description": "Whether the first line tax applies. NolaPro carries up to three taxes per line."
                    },
                    "costeach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "products_tax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(7,4)`.",
                        "x-decimals": 4
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line description printed on the order."
                    },
                    "saleunitperpriceunit": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "costglaccountid": {
                        "type": "integer",
                        "description": "Reference to `glaccounts`, by id. Write either this or `costglaccount`."
                    },
                    "costglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `costglaccountid`, not both unless they agree."
                    },
                    "purchaseunitid": {
                        "type": "integer",
                        "description": "Unit the line is purchased in, from `unitnames`."
                    },
                    "purchaseunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `purchaseunitid`, not both unless they agree."
                    },
                    "priceunitid": {
                        "type": "integer",
                        "description": "Unit the line is priced in, from `unitnames`."
                    },
                    "priceunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `priceunitid`, not both unless they agree."
                    },
                    "main_arorderdetailid": {
                        "type": "integer",
                        "description": "Main arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptiongroupid": {
                        "type": "integer",
                        "description": "Itemoptiongroupid. Id only.",
                        "x-idonly": true
                    },
                    "itemoptionid": {
                        "type": "integer",
                        "description": "Itemoptionid. Id only.",
                        "x-idonly": true
                    },
                    "multioption": {
                        "type": "integer",
                        "description": "1 when the line is an option row belonging to a multi-option (options item) main line."
                    },
                    "optionindependent": {
                        "type": "integer",
                        "description": "1 when the option line’s quantity is independent of the main item’s quantity."
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "taxflag2": {
                        "type": "integer",
                        "description": "Whether the second line tax applies."
                    },
                    "taxflag3": {
                        "type": "integer",
                        "description": "Whether the third line tax applies."
                    },
                    "taxflagid": {
                        "type": "integer",
                        "description": "Taxflagid. Id only.",
                        "x-idonly": true
                    },
                    "taxflag2id": {
                        "type": "integer",
                        "description": "Taxflag2id. Id only.",
                        "x-idonly": true
                    },
                    "taxflag3id": {
                        "type": "integer",
                        "description": "Taxflag3id. Id only.",
                        "x-idonly": true
                    },
                    "itemweight": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "qtyorderprice": {
                        "type": "string",
                        "description": "Quantity, stored as double, as a string. Stored as `double`.",
                        "x-qty": true
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "price_override": {
                        "type": "integer",
                        "description": "1 when the price was manually overridden, so repricing leaves it alone."
                    },
                    "extended_price": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "worktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `worktype`."
                    },
                    "worktype": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced worktype, instead of the id."
                    },
                    "worksubtypeid": {
                        "type": "integer",
                        "description": "Worksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "discount_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "orig_priceach": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "linedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date recorded for the line (service and rental lines)."
                    },
                    "linetype": {
                        "type": "integer",
                        "description": "Line type: 0 = standard product line, 1 = product-type tax, 2 = delivery charge, 3 = fuel charge, 4 = restock fee, 5 = billed expense."
                    },
                    "partialtaxexemptionid": {
                        "type": "integer",
                        "description": "Partial tax exemption applied to the line."
                    },
                    "partialtaxexemption": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `partialtaxexemptionid`, not both unless they agree."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "transfrominventorylocationid": {
                        "type": "integer",
                        "description": "Reference to `inventorylocations`, by id. Write either this or `transfrominventorylocation`."
                    },
                    "transfrominventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `transfrominventorylocationid`, not both unless they agree."
                    },
                    "createpowhenconvertedfrombid": {
                        "type": "boolean",
                        "description": "True creates a purchase order for the line when the quote converts to an order."
                    },
                    "ignoretaxexempt": {
                        "type": "boolean",
                        "description": "True taxes the line even when the customer is tax exempt."
                    },
                    "itempricespecialdetailid": {
                        "type": "integer",
                        "description": "Itempricespecialdetailid. Id only.",
                        "x-idonly": true
                    },
                    "numperiods": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "period": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Rental period the line bills by: D = daily, W = weekly, M = monthly. Empty for non-rental lines."
                    },
                    "producttypetaxid": {
                        "type": "integer",
                        "description": "Producttypetaxid. Id only.",
                        "x-idonly": true
                    },
                    "arserviceorder_timeid": {
                        "type": "integer",
                        "description": "Arserviceorder timeid. Id only.",
                        "x-idonly": true
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "assetidlastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the rental asset assigned to the line last changed."
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "description": "Prpaytypeid. Id only.",
                        "x-idonly": true
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefServiceordertimesCreate": {
                "type": "object",
                "required": [
                    "orderid",
                    "worktypeid"
                ],
                "description": "Hours against an existing, unbilled service order. The worker is exactly one of employeeid or vendorid (or vendor, the code spelling). totalprice, totalcost and the entry status are derived and never accepted. rate and costrate are writable for callers importing what was actually billed; omitted, they derive from the work class rate and the worker exactly as the time screen derives them.",
                "properties": {
                    "orderid": {
                        "type": "integer",
                        "description": "The service order the hours belong to. Must be a service order (422 hours_require_service_order) that has not reached billed (409 order_already_billed).",
                        "x-idonly": true
                    },
                    "employeeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The employee who did the work. Must be active with a work class - the time screen only offers those. Send this or a vendor, never both."
                    },
                    "vendorid": {
                        "type": "integer",
                        "description": "The vendor/subcontractor who did the work. Must carry a work class and not be a child location.",
                        "x-sibling": "vendor"
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The vendor by code instead of id. Same validation either way."
                    },
                    "worktypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The kind of work. GET /serviceworktypes lists them."
                    },
                    "worksubtypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "Optional sub-classification. Must belong to worktypeid."
                    },
                    "hours": {
                        "type": "string",
                        "x-qty": true,
                        "x-decimals": 2,
                        "description": "Hours worked, 2 decimal places, as a string. Negative is a correction. Zero is allowed only with a note - the entry stays a placeholder (status 0) and never bills."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date",
                        "description": "The date the work was done. Defaults to today."
                    },
                    "rate": {
                        "type": "string",
                        "x-money": true,
                        "x-decimals": 4,
                        "description": "The billing rate per hour, in the ORDER currency. When omitted it derives from the work class rate for the worker, converted at the order date, times the pay type multiplier. When sent it is stored as sent - the multiplier is not applied on top."
                    },
                    "costrate": {
                        "type": "string",
                        "x-money": true,
                        "x-decimals": 4,
                        "description": "Cost per hour to the company, in the company BASE currency. When omitted it derives from the worker: fringe-loaded pay for an employee, default cost per hour for a vendor."
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Customer-visible notes. Concatenated onto the invoice line when hours convert."
                    },
                    "internal_comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Internal notes. Never shown to the customer."
                    },
                    "techname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Technician name override. Defaults from the worker."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "Tax class, when labor is taxable."
                    },
                    "assetid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The customer asset being serviced."
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "AR pay type (straight time, overtime...). Only pay types flagged for AR are accepted - the screen offers no others."
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "x-number": true,
                        "x-decimals": 2,
                        "description": "Rate multiplier. Defaults to the pay type's own multiplier, else 1.00. Applied only when rate is derived."
                    },
                    "startdatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Timer start, for entries imported from a timer."
                    },
                    "enddatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Timer stop."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                },
                "additionalProperties": false
            },
            "RefPurchaseorderlinesCreate": {
                "type": "object",
                "description": "A line on the purchase order. The parent id is not sent - the nesting says which PO.",
                "properties": {
                    "itemid": {
                        "type": "integer",
                        "description": "Reference to `items`, by id. Write either this or `item`."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The `sku` of the referenced items, instead of the id. Send this or `itemid`, not both unless they agree."
                    },
                    "itemqty": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "itemprice": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "detail_description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Line description printed on the PO."
                    },
                    "inv_glacct": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `double`."
                    },
                    "conversion": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "itemvendorid": {
                        "type": "integer",
                        "description": "Itemvendorid. Id only.",
                        "x-idonly": true
                    },
                    "purchaseunitid": {
                        "type": "integer",
                        "description": "Unit the line is purchased in, from `unitnames`."
                    },
                    "purchaseunit": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `unitname` of the referenced unitnames, instead of the id. Send this or `purchaseunitid`, not both unless they agree."
                    },
                    "itempriceqty": {
                        "type": "string",
                        "description": "Quantity, 5 decimal places, as a string. Stored as `decimal(5dp)`.",
                        "x-decimals": 5,
                        "x-qty": true
                    },
                    "notes": {
                        "type": "string",
                        "maxLength": 500,
                        "description": "Free-form notes on the line."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "taxable": {
                        "type": "integer",
                        "description": "Whether this line is taxed."
                    },
                    "detailrow": {
                        "type": "integer",
                        "description": "Position of the line on the PO."
                    },
                    "tax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "reqshipdate": {
                        "type": "string",
                        "format": "date",
                        "description": "Ship date requested from the vendor for this line."
                    },
                    "accepted": {
                        "type": "integer",
                        "description": "1 once the line is marked Accepted on the PO screen."
                    },
                    "arorderdetailid": {
                        "type": "integer",
                        "description": "Arorderdetailid. Id only.",
                        "x-idonly": true
                    },
                    "donotupdatelastpocost": {
                        "type": "boolean",
                        "description": "True keeps receipts of this line from updating the item’s last PO cost."
                    },
                    "linenumber": {
                        "type": "integer",
                        "description": "Position of this line on its document, starting at 1."
                    },
                    "linetype": {
                        "type": "integer",
                        "description": "Line type: 0 = standard product line; other values mark charge lines."
                    },
                    "assetid": {
                        "type": "integer",
                        "description": "Assetid. Id only.",
                        "x-idonly": true
                    },
                    "createasset": {
                        "type": "boolean",
                        "description": "True creates a fixed asset from the line when it is received."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefShipmentlinesCreate": {
                "type": "object",
                "description": "One line of a shipment: how much of one order line went out.",
                "properties": {
                    "orderdetailid": {
                        "type": "integer",
                        "description": "The `orderlines` id being shipped, i.e. `arorderdetail.id`. Must belong to this order. Id only - an order line has no human key of its own; it is identified by its position on its order.",
                        "x-idonly": true
                    },
                    "lineindex": {
                        "type": "integer",
                        "description": "Zero-based index into the `lines` array of the **same** request, for shipping a line that has no id yet. Not a column - it exists only in the request. Use instead of `orderdetailid` when nesting inside `POST /orders`; sending both is `422 conflicting_reference`.",
                        "x-synthetic": true
                    },
                    "shipqty": {
                        "type": "string",
                        "x-qty": true,
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6
                    }
                }
            },
            "RefShipmentsCreate": {
                "type": "object",
                "description": "A shipment against the order. Goes through `Arorder_model::ship()`, the same path the shipping screen uses, after the order and its lines exist. **A quote cannot ship** (`422 cannot_ship_quote`). `invoiceid` and `voucherid` are set by invoicing, not here.",
                "x-children": [
                    "lines"
                ],
                "properties": {
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Carrier service the shipment goes out by."
                    },
                    "carrierservice": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrierservice, instead of the id."
                    },
                    "shipdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When it went out."
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Shiptoid. Id only.",
                        "x-idonly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "lines": {
                        "type": "array",
                        "description": "What went out. A shipment left with no lines once zero-quantity rows are dropped is a `422` rather than an empty shipment.",
                        "items": {
                            "$ref": "#/components/schemas/RefShipmentlinesCreate"
                        }
                    }
                }
            },
            "RefOrdersCreate": {
                "type": "object",
                "description": "An order, quote or service order, optionally with its lines, its service hours and shipments against it in the same request. Saved in that order inside **one** transaction, so a rejected shipment means no order either. `ordertype` is `fulfillment`, `service` or `rental`; `status` is `quote`, `unconfirmed`, `open`, `partial` or `billed`. A quote is `status: \"quote\"` - it is not an order type.",
                "x-children": [
                    "lines",
                    "hours",
                    "shipments"
                ],
                "properties": {
                    "ordernumber": {
                        "type": "integer",
                        "description": "Equals `id` - set by the system immediately after insert, kept only for legacy joins. Not a sequence, not money (the column is a double for historical reasons), and never writable. The human-facing number is `onum`.",
                        "readOnly": true
                    },
                    "onum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Display order number when it differs from the record id; imported orders keep their original numbers here."
                    },
                    "ponumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The customer's purchase order number."
                    },
                    "orderbycompanyid": {
                        "type": "integer",
                        "description": "Orderbycompanyid. Id only.",
                        "x-idonly": true
                    },
                    "shiptocompanyid": {
                        "type": "integer",
                        "description": "Shiptocompanyid. Id only.",
                        "x-idonly": true
                    },
                    "status": {
                        "type": "string",
                        "description": "Where the document is in its life. **A quote is a status, not an order type**, and it wins over `ordertype`. Stored as int -1/-2/0/1/2; never exposed or accepted (D35).",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    },
                    "customerbillcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Customer Bill Code printed on order documents."
                    },
                    "pricelevelid": {
                        "type": "integer",
                        "description": "Pricelevelid. Id only.",
                        "x-idonly": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `inventorylocationid`, not both unless they agree."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "payment_method": {
                        "type": "string",
                        "maxLength": 12,
                        "description": "Payment method text carried in from the web store order."
                    },
                    "shipping_method": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Shipping method text carried in from the web store order."
                    },
                    "orders_date_finished": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the web store marked the order finished."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the order is priced in."
                    },
                    "transaction_id": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Payment gateway reference. Read-only: written by the gateway, never by a caller.",
                        "readOnly": true
                    },
                    "customers_id": {
                        "type": "integer",
                        "description": "Customer id in the osCommerce-style web store tables, for cart integrations."
                    },
                    "customers": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `customers_id`, not both unless they agree."
                    },
                    "shipping_cost": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "order_weight": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "currency_value": {
                        "type": "string",
                        "description": "Numeric string, 6 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 6,
                        "x-number": true
                    },
                    "wherefrom": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Module or channel that created the order; empty for orders entered in NolaPro."
                    },
                    "confirmed_by": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Who confirmed the order."
                    },
                    "confirmed_date": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Date the order was confirmed."
                    },
                    "confirmed": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "1 once the order is confirmed with the customer."
                    },
                    "paymeth": {
                        "type": "integer",
                        "description": "Payment method: 1 = cash, 2 = check, 3 = credit card, 4 = ACH/EFT, 5 = card terminal; 0 = on account or unset."
                    },
                    "ordertype": {
                        "type": "string",
                        "description": "What kind of document this is. Stored as int 0/1/2; the integer is never exposed or accepted (D35).",
                        "enum": [
                            "fulfillment",
                            "service",
                            "rental"
                        ]
                    },
                    "estimate": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "deposit": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "salesmanid": {
                        "type": "integer",
                        "description": "Reference to `salesmen`, by id. Write either this or `salesman`."
                    },
                    "salesman": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced salesmen, instead of the id. Send this or `salesmanid`, not both unless they agree."
                    },
                    "sales_categoriesid": {
                        "type": "integer",
                        "description": "Sales category the order reports under."
                    },
                    "sales_categories": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `description` of the referenced salescategories, instead of the id. Send this or `sales_categoriesid`, not both unless they agree."
                    },
                    "statusid": {
                        "type": "integer",
                        "description": "Statusid. Id only.",
                        "x-idonly": true
                    },
                    "rma_arorder_returnedid": {
                        "type": "integer",
                        "description": "Rma arorder returnedid. Id only.",
                        "x-idonly": true
                    },
                    "rma_orig_arorderid": {
                        "type": "integer",
                        "description": "Rma orig arorderid. Id only.",
                        "x-idonly": true
                    },
                    "carrierserviceid_preferred": {
                        "type": "integer",
                        "description": "Carrier service the customer prefers for shipping this order."
                    },
                    "finalship": {
                        "type": "integer",
                        "description": "1 when the order is Marked Final - no more shipments are expected."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "arglaccountid": {
                        "type": "integer",
                        "description": "Arglaccountid. Id only."
                    },
                    "arglaccount": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `name` of the referenced glaccounts, instead of the id. Send this or `arglaccountid`, not both unless they agree."
                    },
                    "defaultworktypeid": {
                        "type": "integer",
                        "description": "Reference to `worktypes`, by id. Write either this or `defaultworktype`."
                    },
                    "defaultworktype": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced worktypes, instead of the id. Send this or `defaultworktypeid`, not both unless they agree."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "defaultworksubtypeid": {
                        "type": "integer",
                        "description": "Defaultworksubtypeid. Id only.",
                        "x-idonly": true
                    },
                    "stageid": {
                        "type": "integer",
                        "description": "Stageid. Id only.",
                        "x-idonly": true
                    },
                    "edi": {
                        "type": "integer",
                        "description": "1 when the order arrived through EDI."
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "outsidesalesmargin": {
                        "type": "integer",
                        "description": "Margin percentage used for outside-sales commission on the order; -1 when the margin was overridden."
                    },
                    "ediasn": {
                        "type": "integer",
                        "description": "1 once the EDI advance ship notice (ASN) has been sent for the order."
                    },
                    "ediinvoice": {
                        "type": "integer",
                        "description": "1 once the invoice has been sent through EDI."
                    },
                    "defaultvendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `defaultvendor`."
                    },
                    "defaultvendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `defaultvendorid`, not both unless they agree."
                    },
                    "shippingnotes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Shippingnotes. Stored as `text`, no practical length limit."
                    },
                    "contactnameid": {
                        "type": "integer",
                        "description": "Contactnameid. Id only.",
                        "x-idonly": true
                    },
                    "dropship": {
                        "type": "boolean",
                        "description": "True when the order drop-ships from the vendor directly to the customer."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "description": "Taxclassid. Id only."
                    },
                    "taxclass": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "The `name` of the referenced taxclasses, instead of the id. Send this or `taxclassid`, not both unless they agree."
                    },
                    "unread": {
                        "type": "boolean",
                        "description": "1 until someone opens the order in NolaPro; new web and B2B orders arrive unread."
                    },
                    "clonedquotearorderid": {
                        "type": "integer",
                        "description": "Clonedquotearorderid. Id only.",
                        "x-idonly": true
                    },
                    "ordertotal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "rentalsbillwhen": {
                        "type": "boolean",
                        "description": "For rental orders: when rentals bill (0 = on return, 1 = periodically while out)."
                    },
                    "signaturerequired": {
                        "type": "boolean",
                        "description": "1 when delivery requires a signature."
                    },
                    "taxexemptid": {
                        "type": "integer",
                        "description": "Reference to `taxexempts`, by id. Write either this or `taxexempt`."
                    },
                    "taxexempt": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "The `exemptname` of the referenced taxexempts, instead of the id. Send this or `taxexemptid`, not both unless they agree."
                    },
                    "usecontactdetails": {
                        "type": "boolean",
                        "description": "1 prints the order contact’s details on documents instead of the customer’s main details."
                    },
                    "billtoshiptoid": {
                        "type": "integer",
                        "description": "Billtoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "defaultassetid": {
                        "type": "integer",
                        "description": "Defaultassetid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucontactid": {
                        "type": "integer",
                        "description": "Passthrucontactid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerbilltoshiptoid": {
                        "type": "integer",
                        "description": "Passthrucustomerbilltoshiptoid. Id only.",
                        "x-idonly": true
                    },
                    "passthrucustomerid": {
                        "type": "integer",
                        "description": "Passthrucustomerid. Id only."
                    },
                    "passthrucustomer": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `passthrucustomerid`, not both unless they agree."
                    },
                    "ordernumberdisplay": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it, and a value sent here is silently discarded.",
                        "readOnly": true
                    },
                    "estimatedmultiplier": {
                        "type": "integer",
                        "description": "Estimated Multiplier applied when estimating the order’s pricing."
                    },
                    "hidebettervalueinfopdf": {
                        "type": "integer",
                        "description": "1 hides the better-value pricing block on the printed quote PDF."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "lines": {
                        "type": "array",
                        "description": "Lines on the order, in the order given.",
                        "items": {
                            "$ref": "#/components/schemas/RefOrderlinesCreate"
                        }
                    },
                    "hours": {
                        "type": "array",
                        "description": "Service hours. Only when `ordertype` is `service`.",
                        "items": {
                            "$ref": "#/components/schemas/RefServiceordertimesCreate"
                        }
                    },
                    "shipments": {
                        "type": "array",
                        "description": "Ship part or all of the order in the same request. Refused when `status` is `quote`. Reference the new lines by `lineindex`.",
                        "items": {
                            "$ref": "#/components/schemas/RefShipmentsCreate"
                        }
                    }
                }
            },
            "RefPurchaseordersCreate": {
                "type": "object",
                "description": "A purchase order, optionally with its lines in the same request. Omit `ponumber` entirely to have one assigned under a lock - an empty string means an explicit blank, not \"assign me one\". A proposal is `status: \"proposal\"`, the same shape as an AR quote.",
                "x-children": [
                    "lines"
                ],
                "properties": {
                    "vendorid": {
                        "type": "integer",
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`."
                    },
                    "vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced vendor, instead of the id."
                    },
                    "ponumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The customer's purchase order number."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date payment is due."
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into."
                    },
                    "location": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `locationcode` of the referenced inventorylocations, instead of the id. Send this or `locationid`, not both unless they agree."
                    },
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Carrier service the purchase order ships by."
                    },
                    "carrierservice": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Code for the referenced carrierservice, instead of the id."
                    },
                    "tracknumber": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Carrier tracking number."
                    },
                    "contact": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Vendor contact for the purchase order."
                    },
                    "requisition": {
                        "type": "string",
                        "maxLength": 22,
                        "description": "Requisition reference."
                    },
                    "ordernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Order # of the sales order this PO buys for, when the PO was pulled from an order."
                    },
                    "complete": {
                        "type": "integer",
                        "description": "1 when the PO is complete - fully received or manually closed; no further receipts are expected."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Referenceid. Id only.",
                        "x-idonly": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "initials": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Buyer initials shown on the PO."
                    },
                    "status": {
                        "type": "string",
                        "description": "A proposal is the PO version of a quote - one field flip converts it. `Partial` and `Complete` are not statuses: see `effectivestatus` and `complete`. Stored as int -1/0; never exposed (D35).",
                        "enum": [
                            "proposal",
                            "open"
                        ]
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Purchase order description."
                    },
                    "wherefrom": {
                        "type": "integer",
                        "description": "Where the PO originated; 0 for POs entered on the purchase order screen."
                    },
                    "salesordernumber": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Sales Order Number reference shown on the PO."
                    },
                    "dropship": {
                        "type": "integer",
                        "description": "1 when the PO drop-ships from the vendor directly to the customer."
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Shiptoid. Id only.",
                        "x-idonly": true
                    },
                    "salesorderid": {
                        "type": "integer",
                        "description": "Salesorderid. Id only.",
                        "x-idonly": true
                    },
                    "paytermsid": {
                        "type": "integer",
                        "description": "Paytermsid. Id only - the table this points at is not identifiable from the column name, so there is no human key to send instead."
                    },
                    "payterms": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Code for the referenced invoiceterms, instead of the id."
                    },
                    "ccpurchaseid": {
                        "type": "integer",
                        "description": "Ccpurchaseid. Id only.",
                        "x-idonly": true
                    },
                    "stageid": {
                        "type": "integer",
                        "description": "Stageid. Id only.",
                        "x-idonly": true
                    },
                    "recipient_userid": {
                        "type": "integer",
                        "description": "User who will receive the goods."
                    },
                    "recipient_user": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The `name` of the referenced genusers, instead of the id. Send this or `recipient_userid`, not both unless they agree."
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Jobid. Id only.",
                        "x-idonly": true
                    },
                    "totaltax": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,5)`.",
                        "x-decimals": 5
                    },
                    "main_invpoid": {
                        "type": "integer",
                        "description": "Main invpoid. Id only.",
                        "x-idonly": true
                    },
                    "prior_invpoid": {
                        "type": "integer",
                        "description": "Prior invpoid. Id only.",
                        "x-idonly": true
                    },
                    "retainage": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(12,2)`.",
                        "x-decimals": 2
                    },
                    "fob": {
                        "type": "string",
                        "maxLength": 2,
                        "description": "FOB terms printed on the PO."
                    },
                    "chargeback": {
                        "type": "integer",
                        "description": "1 when the PO is charged back to another vendor."
                    },
                    "chargeback_vendorid": {
                        "type": "integer",
                        "description": "Vendor the chargeback PO is charged back to."
                    },
                    "chargeback_vendor": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `vendorcode` of the referenced vendors, instead of the id. Send this or `chargeback_vendorid`, not both unless they agree."
                    },
                    "chargeback_invpoid": {
                        "type": "integer",
                        "description": "Chargeback invpoid. Id only.",
                        "x-idonly": true
                    },
                    "chargeback_percent": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "pototal": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,6)`.",
                        "x-decimals": 6
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the PO is priced in."
                    },
                    "currate": {
                        "type": "string",
                        "description": "Numeric string, 10 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 10,
                        "x-number": true
                    },
                    "taxrate": {
                        "type": "string",
                        "description": "Numeric string, 2 decimal places. Not money - do not apply currency rounding.",
                        "x-decimals": 2,
                        "x-number": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code."
                    },
                    "costcode": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "Code for the referenced costcode, instead of the id."
                    },
                    "glcategoryid": {
                        "type": "integer",
                        "description": "Glcategoryid. Id only."
                    },
                    "glcategory": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "The `code` of the referenced glcategories, instead of the id. Send this or `glcategoryid`, not both unless they agree."
                    },
                    "return_from_invpoid": {
                        "type": "integer",
                        "description": "Return from invpoid. Id only.",
                        "x-idonly": true
                    },
                    "rtvnumber": {
                        "type": "string",
                        "maxLength": 45,
                        "description": "RTV number, for a return-to-vendor PO."
                    },
                    "vendor_orderfromid": {
                        "type": "integer",
                        "description": "Vendor orderfromid. Id only.",
                        "x-idonly": true
                    },
                    "address1": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Street address."
                    },
                    "address2": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Second address line."
                    },
                    "city": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "City of the PO ship-to address."
                    },
                    "completedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Date the PO was completed."
                    },
                    "customerdropshiptoid": {
                        "type": "integer",
                        "description": "Customer ship-to address a drop-ship PO delivers to."
                    },
                    "customerdropshipto": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The `customercode` of the referenced customers, instead of the id. Send this or `customerdropshiptoid`, not both unless they agree."
                    },
                    "donotupdatelastpocost": {
                        "type": "boolean",
                        "description": "True keeps receipts on this PO from updating the item’s last PO cost (Do Not Update Last PO Cost)."
                    },
                    "headernote": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Headernote. Stored as `text`, no practical length limit."
                    },
                    "prepaid": {
                        "type": "integer",
                        "description": "Prepaid. Id only.",
                        "x-idonly": true
                    },
                    "shipname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Ship To name printed on the PO."
                    },
                    "state": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "State of the PO ship-to address."
                    },
                    "zip": {
                        "type": "string",
                        "maxLength": 15,
                        "description": "Postal code."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    },
                    "lines": {
                        "type": "array",
                        "description": "Lines on the purchase order, in order.",
                        "items": {
                            "$ref": "#/components/schemas/RefPurchaseorderlinesCreate"
                        }
                    }
                }
            },
            "RefInvoiceRun": {
                "type": "object",
                "description": "Options for turning a document into invoices. Every field is optional.",
                "properties": {
                    "invoicedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date to post the invoice under. Defaults to now. Must fall in an open GL period or the run is refused with `period_closed`."
                    }
                }
            },
            "RefInvoiceRunResult": {
                "type": "object",
                "description": "What the run produced. **A run can create more than one invoice** - one order can split across ship-tos and shipments - so this is always a list, even when it holds one id.",
                "properties": {
                    "invoiceids": {
                        "type": "array",
                        "items": {
                            "type": "integer"
                        },
                        "description": "Ids of the invoices created, in creation order."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "The order that was invoiced. Id only - the order is identified by `onum`, which is optional and not unique, so there is no code sibling to offer.",
                        "x-idonly": true
                    },
                    "orderstatus": {
                        "type": "string",
                        "description": "The order's status after the run. A service order becomes `billed`; a fulfillment order stays `open` or `partial` while quantity remains unbilled.",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    }
                }
            },
            "RefOrderdeposits": {
                "type": "object",
                "description": "Deposits taken against an order. **A deposit alone makes an order invoiceable** - `arorder2invoice.php` admits an order that has a deposit even when nothing has shipped. Card brand and number are never returned.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "orderid": {
                        "type": "integer",
                        "description": "Orderid. Id only.",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "payment_method": {
                        "type": "integer",
                        "description": "Payment method text carried in from the web store order."
                    },
                    "transaction_id": {
                        "type": "string",
                        "maxLength": 32,
                        "description": "Gateway transaction id of the deposit payment."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date",
                        "description": "When the record was created."
                    },
                    "last4ofcard": {
                        "type": "string",
                        "maxLength": 4,
                        "description": "Last four digits, for matching a deposit to a statement line. Read-only - written by the card terminal, never by a caller.",
                        "readOnly": true
                    },
                    "voucherid": {
                        "type": "integer",
                        "description": "GL voucher. Read-only - set when the deposit posts.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "bankdepositid": {
                        "type": "integer",
                        "description": "The bank deposit this was included in. Read-only - set by Bank Rec.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "cctransactionid": {
                        "type": "integer",
                        "description": "The card transaction that produced this deposit. Read-only.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "checkid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Check number or payment reference the deposit was paid with."
                    },
                    "bankstatement_enddate": {
                        "type": "string",
                        "format": "date",
                        "description": "Set by Bank Reconciliation. Read-only.",
                        "readOnly": true
                    },
                    "checkacctid": {
                        "type": "integer",
                        "description": "Bank account the deposit lands in."
                    },
                    "checkacct": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Bank account name (`checkacct.name`) instead of the id."
                    },
                    "currency": {
                        "type": "string",
                        "maxLength": 10,
                        "description": "Currency the deposit was received in."
                    },
                    "returned": {
                        "type": "integer",
                        "description": "1 when the deposit payment was returned by the bank (NSF/bounced)."
                    },
                    "bankfee_amount": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "bankfee_glid": {
                        "type": "integer",
                        "description": "GL account any bank fee on this deposit posts to."
                    },
                    "bankfee_gl": {
                        "type": "string",
                        "maxLength": 20,
                        "description": "GL account number (`glaccount.accountnum`) instead of the id."
                    },
                    "rnum": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Reference number recorded with the deposit."
                    },
                    "tendered": {
                        "type": "string",
                        "x-money": true,
                        "description": "Stored as `decimal(19,4)`.",
                        "x-decimals": 4
                    },
                    "ccterminalid": {
                        "type": "integer",
                        "description": "Terminal that took it. Read-only.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "bankstatement_cleardate": {
                        "type": "string",
                        "format": "date",
                        "description": "Set by Bank Reconciliation. Read-only.",
                        "readOnly": true
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Notes. Stored as `text`, no practical length limit."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemidentifiers": {
                "type": "object",
                "description": "What this company tracks per item: serial number, lot, expiry. `datatype` is the value shape; `singleton` means one unit per value, which is how a serial number differs from a lot.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "name": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "Name of the identifier, shown wherever values are entered (e.g. Serial #, Lot)."
                    },
                    "datatype": {
                        "type": "string",
                        "maxLength": 1,
                        "description": "Value type: empty = text, D = date (dates get parsed and expiration handling)."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "showonpicklist": {
                        "type": "boolean",
                        "description": "True prints the identifier value on pick lists."
                    },
                    "showonorderconf": {
                        "type": "boolean",
                        "description": "True prints the identifier value on order confirmations."
                    },
                    "showoninvoice": {
                        "type": "boolean",
                        "description": "True prints the identifier value on invoices."
                    },
                    "showonpackingslip": {
                        "type": "boolean",
                        "description": "True prints the identifier value on packing slips."
                    },
                    "singleton": {
                        "type": "boolean",
                        "description": "True when each value tracks a single unit (serial numbers); false when a value can cover a quantity (lots)."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemidentifierdetails": {
                "type": "object",
                "description": "The actual serials and lots in stock, per item and location. `quantityonhand` and `quantityavailable` are generated columns and are never writable.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Itemid. Id only."
                    },
                    "item": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "Item number (`item.itemnum`) instead of the id."
                    },
                    "itemidentifierid": {
                        "type": "integer",
                        "description": "Itemidentifierid. Id only.",
                        "x-idonly": true
                    },
                    "itemidentifiervalue": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The recorded identifier value (serial or lot number)."
                    },
                    "itemidentifiervaluedate": {
                        "type": "string",
                        "format": "date",
                        "description": "The value parsed as a date, when the identifier is date-typed (expiration dates)."
                    },
                    "quantityreceived": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "quantitycommitted": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "quantityused": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "itemidentifierdetailgroupid": {
                        "type": "integer",
                        "description": "Groups values received together. There is no such table - it is an internal grouping key assigned on receipt. Read-only.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only."
                    },
                    "inventorylocation": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Location name instead of the id."
                    },
                    "quantityonhand": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "readOnly": true,
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "quantityavailable": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "readOnly": true,
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "hasquantityonhand": {
                        "type": "boolean",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it.",
                        "readOnly": true
                    },
                    "hasquantityavailable": {
                        "type": "boolean",
                        "description": "STORED GENERATED in the database. Read-only - MySQL computes it.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "RefItemidentifiertransactions": {
                "type": "object",
                "description": "**Read-only.** Which serials and lots moved on which shipment or receipt. Written by the transaction that moved them, never directly - a movement with no transaction behind it would be a stock record nothing can explain.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "itemidentifierdetailid": {
                        "type": "integer",
                        "description": "Itemidentifierdetailid. Id only.",
                        "x-idonly": true
                    },
                    "itemtransactionid": {
                        "type": "integer",
                        "description": "The inventory transaction that moved these units. The stock ledger is not exposed. Read-only.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "quantity": {
                        "type": "string",
                        "description": "Quantity, 6 decimal places, as a string. Stored as `decimal(6dp)`.",
                        "x-decimals": 6,
                        "x-qty": true
                    },
                    "inventorylocationid": {
                        "type": "integer",
                        "description": "Inventorylocationid. Id only.",
                        "x-idonly": true
                    },
                    "trtype": {
                        "type": "integer",
                        "description": "Movement type: 1 = committed to an order, 2 = purchase (PO receipt), 3 = sales/use (shipment), 4 = manual adjustment."
                    },
                    "referencetable": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Table of the document that moved the identifier (invreceive, arordershipdetail, rma_arorder_detail_returned, ...)."
                    },
                    "referenceid": {
                        "type": "integer",
                        "description": "Referenceid. Id only.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "User-visible note on the movement."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. NolaPro cancels rather than deletes, so a cancelled row is still readable."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the record was created."
                    }
                }
            },
            "RefWebhookEvent": {
                "type": "object",
                "description": "The body delivered to your endpoint. Identical for every event type; only `type` and `data` differ.",
                "properties": {
                    "id": {
                        "type": "string",
                        "maxLength": 40,
                        "description": "Unique per delivery attempt-group. **Use it to deduplicate** - delivery is at-least-once, so the same `id` can arrive twice."
                    },
                    "type": {
                        "type": "string",
                        "maxLength": 60,
                        "enum": [
                            "customers.created",
                            "customers.updated",
                            "customers.cancelled",
                            "orders.created",
                            "orders.updated",
                            "orders.cancelled",
                            "orders.invoiced",
                            "shipments.created",
                            "shipments.cancelled",
                            "invoices.posted",
                            "invoices.cancelled",
                            "payments.created",
                            "payments.cancelled",
                            "orderdeposits.created",
                            "purchaseorders.created",
                            "purchaseorders.updated",
                            "purchaseorders.cancelled",
                            "invreceives.created",
                            "items.created",
                            "items.updated",
                            "items.stockchanged",
                            "serviceordertimes.billed",
                            "itemidentifierdetails.created",
                            "itemidentifierdetails.updated"
                        ],
                        "description": "Which event this is."
                    },
                    "createdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the change happened, not when we sent it. A retry two hours later still carries the original time."
                    },
                    "companyid": {
                        "type": "integer",
                        "description": "The NolaPro company the change happened in. Delivered to you; never sent by you.",
                        "x-idonly": true,
                        "readOnly": true
                    },
                    "data": {
                        "type": "object",
                        "description": "The record, in the same shape `GET` returns it. It is a **snapshot taken when the event fired** - on a retry it may already be out of date, so re-read the record if you need certainty."
                    }
                }
            },
            "RefWebhooks": {
                "type": "object",
                "description": "A webhook subscription.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "url": {
                        "type": "string",
                        "maxLength": 500,
                        "description": "HTTPS endpoint to POST to. Plain HTTP is refused - the payload carries business data and the signature is worthless over a channel anyone can read."
                    },
                    "events": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        },
                        "description": "Event types to receive. `*` is not accepted: naming them is what stops a new event type silently appearing in your handler."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "What this subscription is for. Shown on the token screen."
                    },
                    "paused": {
                        "type": "boolean",
                        "description": "Pause delivery without cancelling the subscription. A paused subscription drops events rather than queueing them - it is a tap, not a buffer. Deliberately not called `active`: D23 reserves that word, and `cancel` already means something else here."
                    },
                    "failcount": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Consecutive failed deliveries. Resets on the first success."
                    },
                    "lastdeliverydate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last successful delivery."
                    },
                    "disableddate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Set when we gave up. See the disabling rule in Webhooks."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled.",
                        "readOnly": true
                    },
                    "enabled": {
                        "type": "boolean",
                        "description": "Write-only. Send `true` to revive a subscription we disabled after six failed deliveries: it clears `disableddate` AND resets `failcount`, so it gets a fresh six. Clearing the date alone would disable it again on the next failure. Not the same as `paused`, which is your own on/off switch and never resets anything.",
                        "x-synthetic": true
                    }
                }
            },
            "ListMeta": {
                "type": "object",
                "description": "Present only on a delta poll (`modifiedsince`).",
                "properties": {
                    "synced_through": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Store it and send it back as your next `modifiedsince`. Taken before the query ran, so nothing can fall between two polls."
                    }
                }
            },
            "RefGlaccountBalance": {
                "type": "object",
                "description": "An account balance, **per currency**. NolaPro posts in the transaction currency, so an account can hold more than one and summing them would be meaningless.",
                "properties": {
                    "glaccountid": {
                        "type": "integer",
                        "readOnly": true,
                        "x-idonly": true,
                        "description": "The account. Id only - an account is keyed by `accountnum`, which is already on the record."
                    },
                    "asofdate": {
                        "type": "string",
                        "format": "date",
                        "description": "The as-of date used. Defaults to the end of the current GL period, honouring a 4-4-5 calendar when one is configured."
                    },
                    "balances": {
                        "type": "array",
                        "description": "One entry per currency the account holds.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "currency": {
                                    "type": "string",
                                    "maxLength": 10
                                },
                                "balance": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "description": "Balance as of `asofdate`."
                                },
                                "period": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "description": "Net movement within the period containing `asofdate`."
                                }
                            }
                        }
                    }
                }
            },
            "RefCustomerBalance": {
                "type": "object",
                "description": "What a customer owes, **per currency**. Invoices are held in the currency they were raised in, so a customer can owe in more than one and a single total would be a fiction.",
                "properties": {
                    "customerid": {
                        "description": "Reference to `customers`, by id. Write either this or `customer`.",
                        "type": "integer",
                        "readOnly": true,
                        "x-idonly": true
                    },
                    "asofdate": {
                        "type": "string",
                        "format": "date",
                        "description": "The as-of date used. Defaults to today."
                    },
                    "balances": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "currency": {
                                    "type": "string",
                                    "maxLength": 10
                                },
                                "balance": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "description": "Total open, the sum of every bucket."
                                }
                            }
                        }
                    }
                }
            },
            "RefCustomerAging": {
                "type": "object",
                "description": "The same open balance broken into aging buckets, per currency.\n\nThe buckets are **fixed by this API** at current / 0-30 / 31-60 / 61-90 / 91+. The Aging report lets a user choose their own, but a response whose shape moves when someone edits a report setting is not something an integration can parse, so the API pins them.\n\nWhether aging runs from the invoice date or the due date, and whether credit memos are included, still follow the company AR settings - those change the numbers, not the shape.",
                "properties": {
                    "customerid": {
                        "description": "Reference to `customers`, by id. Write either this or `customer`.",
                        "type": "integer",
                        "readOnly": true,
                        "x-idonly": true
                    },
                    "asofdate": {
                        "type": "string",
                        "format": "date"
                    },
                    "aging": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "currency": {
                                    "type": "string",
                                    "maxLength": 10
                                },
                                "balance": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "description": "Total open in this currency."
                                },
                                "current": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "description": "Not yet overdue."
                                },
                                "buckets": {
                                    "type": "array",
                                    "items": {
                                        "type": "object",
                                        "properties": {
                                            "label": {
                                                "type": "string",
                                                "description": "e.g. `31-60`, `91+`."
                                            },
                                            "fromdays": {
                                                "type": "integer"
                                            },
                                            "todays": {
                                                "type": "integer",
                                                "nullable": true,
                                                "description": "`null` on the open-ended oldest bucket."
                                            },
                                            "amount": {
                                                "type": "string",
                                                "x-money": true,
                                                "x-decimals": 4,
                                                "description": "Open in this bucket."
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "RefGlaccountActivity": {
                "type": "object",
                "description": "The posted transaction lines that make up an account balance, newest first.",
                "properties": {
                    "data": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "id": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "description": "The transaction line id."
                                },
                                "voucherid": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "x-idonly": true,
                                    "description": "The voucher this line belongs to."
                                },
                                "voucher": {
                                    "type": "string",
                                    "maxLength": 50,
                                    "readOnly": true,
                                    "description": "The voucher number a person would quote."
                                },
                                "date": {
                                    "type": "string",
                                    "format": "date",
                                    "readOnly": true,
                                    "description": "The GL period the voucher posted to (`post2date`), which is what the balance is measured against - not the day it was keyed."
                                },
                                "posteddate": {
                                    "type": "string",
                                    "format": "date-time",
                                    "readOnly": true,
                                    "description": "When it was actually posted."
                                },
                                "description": {
                                    "type": "string",
                                    "maxLength": 50,
                                    "readOnly": true,
                                    "description": "The voucher description."
                                },
                                "transdesc": {
                                    "type": "string",
                                    "maxLength": 50,
                                    "readOnly": true,
                                    "description": "The line description, where one was entered."
                                },
                                "amount": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "readOnly": true,
                                    "description": "Signed. Debits positive, credits negative; the lines of one voucher sum to zero."
                                },
                                "currency": {
                                    "type": "string",
                                    "maxLength": 10,
                                    "readOnly": true
                                },
                                "jobid": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "x-idonly": true
                                },
                                "costcodeid": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "x-idonly": true
                                },
                                "glcategoryid": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "x-idonly": true
                                },
                                "departmentid": {
                                    "type": "integer",
                                    "readOnly": true,
                                    "x-idonly": true
                                }
                            }
                        }
                    },
                    "page": {
                        "description": "1-based page number.",
                        "type": "integer"
                    },
                    "perpage": {
                        "description": "Page size in effect.",
                        "type": "integer"
                    },
                    "total": {
                        "type": "integer"
                    }
                }
            },
            "GlTransactionCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "readOnly": true,
                        "x-idonly": true
                    },
                    "voucher": {
                        "type": "string",
                        "readOnly": true,
                        "description": "The voucher number, assigned by NolaPro if you did not send one.",
                        "maxLength": 50
                    },
                    "date": {
                        "type": "string",
                        "format": "date",
                        "readOnly": true
                    },
                    "post2date": {
                        "type": "string",
                        "format": "date",
                        "readOnly": true,
                        "description": "The GL period the entry landed in."
                    },
                    "memo": {
                        "type": "string",
                        "readOnly": true,
                        "maxLength": 50
                    },
                    "posted": {
                        "type": "boolean",
                        "readOnly": true,
                        "description": "Always true. The API posts the entry; an unposted voucher is a draft the ledger does not know about."
                    },
                    "externalid": {
                        "type": "string",
                        "readOnly": true,
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "readOnly": true,
                        "items": {
                            "type": "object",
                            "properties": {
                                "id": {
                                    "type": "integer",
                                    "readOnly": true
                                },
                                "glaccountid": {
                                    "type": "integer",
                                    "readOnly": true
                                },
                                "glaccount": {
                                    "type": "string",
                                    "readOnly": true,
                                    "description": "The account number, echoed back so you can show it.",
                                    "maxLength": 20
                                },
                                "amount": {
                                    "type": "string",
                                    "x-money": true,
                                    "x-decimals": 4,
                                    "readOnly": true
                                },
                                "memo": {
                                    "type": "string",
                                    "readOnly": true,
                                    "maxLength": 50
                                }
                            }
                        }
                    }
                }
            },
            "OrderCreate": {
                "type": "object",
                "properties": {
                    "customerid": {
                        "type": "integer",
                        "description": "Who is ordering.",
                        "x-idonly": true
                    },
                    "date": {
                        "type": "string",
                        "description": "Order date. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "ponumber": {
                        "type": "string",
                        "description": "The customer's PO number.",
                        "maxLength": 30
                    },
                    "shiptoid": {
                        "type": "integer",
                        "description": "Ship-to company, if different from the customer.",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "description": "Order number. Leave it out and NolaPro allocates one.",
                        "maxLength": 30
                    },
                    "ordertype": {
                        "type": "string",
                        "description": "Order type: fulfillment, service, or rental.",
                        "enum": [
                            "fulfillment",
                            "service",
                            "rental"
                        ]
                    },
                    "status": {
                        "type": "string",
                        "description": "Send `quote` to raise a quote, which does NOT commit stock. Anything else confirms the order and reserves inventory.",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 1,
                        "items": {
                            "type": "object",
                            "properties": {
                                "itemid": {
                                    "type": "integer",
                                    "description": "Stock item. Omit for a non-stock line and send a description.",
                                    "x-idonly": true
                                },
                                "description": {
                                    "type": "string",
                                    "description": "Line text. Defaults to the item description when itemid is given.",
                                    "maxLength": 255
                                },
                                "quantity": {
                                    "type": "string",
                                    "description": "How many. Decimal STRING, up to 6 places.",
                                    "example": "3.000000",
                                    "x-qty": true
                                },
                                "price": {
                                    "type": "string",
                                    "description": "Unit price. Decimal STRING, not a JSON number.",
                                    "example": "125.0000",
                                    "x-money": true
                                },
                                "taxable": {
                                    "type": "boolean",
                                    "description": "Whether the line attracts tax."
                                }
                            },
                            "required": [
                                "quantity"
                            ]
                        },
                        "description": "At least one line. The total is derived - do not send it."
                    }
                },
                "required": [
                    "customerid",
                    "lines"
                ],
                "additionalProperties": false
            },
            "PaymentCreate": {
                "type": "object",
                "properties": {
                    "invoiceid": {
                        "type": "integer",
                        "description": "The POSTED invoice being paid.",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "description": "How much was received. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "date": {
                        "type": "string",
                        "description": "Date received. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "method": {
                        "type": "integer",
                        "description": "Payment method id."
                    },
                    "reference": {
                        "type": "string",
                        "description": "Cheque number or transaction reference.",
                        "maxLength": 100
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "invoiceid",
                    "amount"
                ],
                "additionalProperties": false
            },
            "ShipmentCreate": {
                "type": "object",
                "properties": {
                    "orderid": {
                        "type": "integer",
                        "description": "The order being shipped against.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 1,
                        "description": "What is going out. Each line ships against an order line and cannot exceed what is left on it.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "orderlineid": {
                                    "type": "integer",
                                    "description": "The `orderlines` id being shipped.",
                                    "x-idonly": true
                                },
                                "quantity": {
                                    "type": "string",
                                    "description": "How many are leaving. Decimal STRING, up to 6 places.",
                                    "example": "3.000000",
                                    "x-qty": true
                                }
                            },
                            "required": [
                                "orderlineid",
                                "quantity"
                            ]
                        }
                    }
                },
                "required": [
                    "orderid",
                    "lines"
                ],
                "additionalProperties": false
            },
            "ApbillCreate": {
                "type": "object",
                "properties": {
                    "vendorid": {
                        "type": "integer",
                        "description": "Who the bill is from.",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "description": "The VENDOR's invoice number. Required - it is how a duplicate bill is spotted, and NolaPro has no counter to fall back on because the number is theirs.",
                        "maxLength": 20
                    },
                    "date": {
                        "type": "string",
                        "description": "Bill date. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "duedate": {
                        "type": "string",
                        "description": "Payment due date.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "total": {
                        "type": "string",
                        "description": "What is owed. Must equal the sum of the distribution lines. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 1,
                        "description": "The GL DISTRIBUTION, not products: each line says which account the expense lands in and for how much. Together they must equal the bill total.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "glaccountid": {
                                    "type": "integer",
                                    "description": "Account id. Or send `glaccount` by name.",
                                    "x-idonly": true
                                },
                                "glaccount": {
                                    "type": "string",
                                    "description": "Account name, matched exactly.",
                                    "maxLength": 60
                                },
                                "amount": {
                                    "type": "string",
                                    "description": "How much of the bill codes to this account. Decimal STRING, not a JSON number.",
                                    "example": "125.0000",
                                    "x-money": true
                                },
                                "jobid": {
                                    "type": "integer",
                                    "description": "Job to cost this to.",
                                    "x-idonly": true
                                },
                                "costcodeid": {
                                    "type": "integer",
                                    "description": "Cost code.",
                                    "x-idonly": true
                                }
                            },
                            "required": [
                                "amount"
                            ]
                        }
                    },
                    "post": {
                        "type": "boolean",
                        "description": "Post the invoice to the general ledger. Defaults to true. Send false to create it as a DRAFT: no GL voucher is written, so lines can still be added with POST /invoicelines or changed with PATCH /invoicelines/{id}. Post it later by cancelling and re-raising, or build it fully before posting. Once an invoice carries a voucher its lines are closed to further change.",
                        "default": true,
                        "example": false
                    }
                },
                "required": [
                    "vendorid",
                    "number",
                    "lines"
                ],
                "additionalProperties": false
            },
            "PurchaseorderCreate": {
                "type": "object",
                "properties": {
                    "vendorid": {
                        "type": "integer",
                        "description": "Who the order is placed with.",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "description": "PO number. Leave it out and NolaPro allocates the next one - which is the normal case.",
                        "maxLength": 20
                    },
                    "date": {
                        "type": "string",
                        "description": "Order date. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "duedate": {
                        "type": "string",
                        "description": "When it is wanted. Defaults to the order date.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "locationid": {
                        "type": "integer",
                        "description": "Inventory location to receive into.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "description": "Free text on the order.",
                        "maxLength": 255
                    },
                    "notes": {
                        "type": "string",
                        "description": "Longer notes.",
                        "x-unbounded": true
                    },
                    "requisition": {
                        "type": "string",
                        "description": "Requisition reference.",
                        "maxLength": 22
                    },
                    "ordernumber": {
                        "type": "string",
                        "description": "Your order number.",
                        "maxLength": 20
                    },
                    "tracknumber": {
                        "type": "string",
                        "description": "Carrier tracking number.",
                        "maxLength": 255
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    },
                    "lines": {
                        "type": "array",
                        "minItems": 1,
                        "description": "At least one line. `pototal` and the line numbers are derived - do not send them.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "itemid": {
                                    "type": "integer",
                                    "description": "Stock item. Omit for a non-stock line and send a description.",
                                    "x-idonly": true
                                },
                                "description": {
                                    "type": "string",
                                    "description": "Line text. Defaults to the item description when itemid is given.",
                                    "maxLength": 255
                                },
                                "quantity": {
                                    "type": "string",
                                    "description": "How many. Decimal STRING, up to 6 places.",
                                    "example": "3.000000",
                                    "x-qty": true
                                },
                                "price": {
                                    "type": "string",
                                    "description": "Unit price. Decimal STRING, not a JSON number.",
                                    "example": "125.0000",
                                    "x-money": true
                                },
                                "itemcode": {
                                    "type": "string",
                                    "description": "Item code, as an alternative to itemid.",
                                    "maxLength": 50
                                },
                                "notes": {
                                    "type": "string",
                                    "description": "Line notes.",
                                    "x-unbounded": true
                                },
                                "jobid": {
                                    "type": "integer",
                                    "description": "Job to cost this to.",
                                    "x-idonly": true
                                },
                                "costcodeid": {
                                    "type": "integer",
                                    "description": "Cost code.",
                                    "x-idonly": true
                                },
                                "reqshipdate": {
                                    "type": "string",
                                    "description": "When this line is wanted.",
                                    "format": "date"
                                }
                            },
                            "required": [
                                "quantity"
                            ]
                        }
                    }
                },
                "required": [
                    "vendorid",
                    "lines"
                ],
                "additionalProperties": false
            },
            "InvoicelineCreate": {
                "type": "object",
                "properties": {
                    "invoiceid": {
                        "type": "integer",
                        "description": "The DRAFT invoice to add to. A posted invoice is refused - its voucher was written for the current total.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Stock item. Omit for a non-stock line and send a description.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "description": "Line text. Defaults to the item description.",
                        "maxLength": 255
                    },
                    "quantity": {
                        "type": "string",
                        "description": "How many. Decimal STRING, up to 6 places.",
                        "example": "3.000000",
                        "x-qty": true
                    },
                    "price": {
                        "type": "string",
                        "description": "Unit price. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "taxable": {
                        "type": "boolean",
                        "description": "Whether the line attracts tax."
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "invoiceid",
                    "quantity",
                    "price"
                ],
                "additionalProperties": false
            },
            "OrderlineCreate": {
                "type": "object",
                "properties": {
                    "orderid": {
                        "type": "integer",
                        "description": "The order to add to. Refused once anything on it has shipped.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Stock item. Omit for a non-stock line and send a description.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "description": "Line text. Defaults to the item description.",
                        "maxLength": 255
                    },
                    "quantity": {
                        "type": "string",
                        "description": "How many. Decimal STRING, up to 6 places.",
                        "example": "3.000000",
                        "x-qty": true
                    },
                    "price": {
                        "type": "string",
                        "description": "Unit price. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "taxable": {
                        "type": "boolean",
                        "description": "Whether the line attracts tax."
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "orderid",
                    "quantity",
                    "price"
                ],
                "additionalProperties": false
            },
            "PurchaseorderlineCreate": {
                "type": "object",
                "properties": {
                    "purchaseorderid": {
                        "type": "integer",
                        "description": "The PO to add to. Refused once it is complete or has receipts.",
                        "x-idonly": true
                    },
                    "itemid": {
                        "type": "integer",
                        "description": "Stock item. Omit for a non-stock line and send a description.",
                        "x-idonly": true
                    },
                    "description": {
                        "type": "string",
                        "description": "Line text. Defaults to the item description.",
                        "maxLength": 255
                    },
                    "quantity": {
                        "type": "string",
                        "description": "How many. Decimal STRING, up to 6 places.",
                        "example": "3.000000",
                        "x-qty": true
                    },
                    "price": {
                        "type": "string",
                        "description": "Unit price. Defaults to 0. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "notes": {
                        "type": "string",
                        "description": "Line notes.",
                        "maxLength": 500
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job to cost this to.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "purchaseorderid",
                    "quantity"
                ],
                "additionalProperties": false
            },
            "ApbilllineCreate": {
                "type": "object",
                "properties": {
                    "apbillid": {
                        "type": "integer",
                        "description": "The UNPOSTED bill to code. A posted bill is refused.",
                        "x-idonly": true
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Account id. Or send `glaccount` by name.",
                        "x-idonly": true
                    },
                    "glaccount": {
                        "type": "string",
                        "description": "Account name, matched exactly.",
                        "maxLength": 60
                    },
                    "amount": {
                        "type": "string",
                        "description": "How much codes to this account. Cannot take the distribution past the bill total. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job to cost this to.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "apbillid",
                    "amount"
                ],
                "additionalProperties": false
            },
            "OrderdepositCreate": {
                "type": "object",
                "properties": {
                    "orderid": {
                        "type": "integer",
                        "description": "The order the deposit is held against.",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "description": "How much was taken. Cannot exceed the order value. Decimal STRING, not a JSON number.",
                        "example": "125.0000",
                        "x-money": true
                    },
                    "date": {
                        "type": "string",
                        "description": "Date taken. Defaults to today.",
                        "format": "date",
                        "example": "2026-08-02"
                    },
                    "method": {
                        "type": "integer",
                        "description": "Payment method id."
                    },
                    "reference": {
                        "type": "string",
                        "description": "Cheque number or transaction reference.",
                        "maxLength": 100
                    },
                    "externalid": {
                        "type": "string",
                        "description": "Your own identifier for this record. Stored verbatim and returned on reads; `GET /<resource>?externalid=...` finds it again.",
                        "example": "crm-8842",
                        "maxLength": 100
                    }
                },
                "required": [
                    "orderid",
                    "amount"
                ],
                "additionalProperties": false
            },
            "InvoiceRun": {
                "type": "object",
                "properties": {
                    "invoicedate": {
                        "type": "string",
                        "format": "date",
                        "description": "Invoice date. Defaults to what NolaPro would use.",
                        "example": "2026-08-02"
                    }
                },
                "additionalProperties": false
            },
            "BatchResult": {
                "type": "object",
                "description": "Per-row outcome. Always 207, never 201 - varying the status by outcome forces you to branch before you know where to read.",
                "properties": {
                    "created": {
                        "type": "integer",
                        "description": "How many rows landed."
                    },
                    "failed": {
                        "type": "integer",
                        "description": "How many were refused."
                    },
                    "results": {
                        "type": "array",
                        "description": "One entry per row, in the order you sent them.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "index": {
                                    "type": "integer",
                                    "description": "Position in your array."
                                },
                                "status": {
                                    "type": "integer",
                                    "description": "201 for a row that landed."
                                },
                                "id": {
                                    "type": "integer",
                                    "description": "Present when the row landed."
                                },
                                "error": {
                                    "type": "object",
                                    "description": "Present when it did not. Same `{code, message, field}` shape as any error."
                                }
                            }
                        }
                    }
                }
            },
            "InvoiceCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "invoicenumber": {
                        "type": "string",
                        "maxLength": 30
                    },
                    "total": {
                        "type": "string",
                        "x-money": true
                    },
                    "posted": {
                        "description": "Always true. The API posts the entry; an unposted voucher is a draft the ledger does not know about.",
                        "type": "boolean"
                    },
                    "voucherid": {
                        "description": "Voucherid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "OrderCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "maxLength": 30
                    },
                    "ordertype": {
                        "type": "string",
                        "enum": [
                            "fulfillment",
                            "service",
                            "rental"
                        ]
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    },
                    "total": {
                        "type": "string",
                        "x-money": true
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "PaymentCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "invoiceid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true
                    },
                    "voucherid": {
                        "description": "Voucherid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "invoicepaid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "ShipmentCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "orderid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "shipdate": {
                        "description": "When it went out.",
                        "type": "string",
                        "format": "date"
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "ApbillCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "vendorid": {
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "maxLength": 30
                    },
                    "total": {
                        "type": "string",
                        "x-money": true
                    },
                    "posted": {
                        "description": "Always true. The API posts the entry; an unposted voucher is a draft the ledger does not know about.",
                        "type": "boolean"
                    },
                    "voucherid": {
                        "description": "Voucherid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "PurchaseorderCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "number": {
                        "type": "string",
                        "maxLength": 30
                    },
                    "vendorid": {
                        "description": "Reference to `vendors`, by id. Write either this or `vendor`.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "total": {
                        "type": "string",
                        "x-money": true
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "quote",
                            "unconfirmed",
                            "open",
                            "partial",
                            "billed"
                        ]
                    },
                    "lines": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "InvoicelineCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "invoiceid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "linenumber": {
                        "description": "Position of this line on its document, starting at 1.",
                        "type": "integer"
                    },
                    "qty": {
                        "type": "string",
                        "x-qty": true
                    },
                    "priceach": {
                        "type": "string",
                        "x-money": true
                    },
                    "totalprice": {
                        "type": "string",
                        "x-money": true
                    },
                    "invoicetotal": {
                        "description": "Stored as `decimal(19,4)`.",
                        "type": "string",
                        "x-money": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "OrderlineCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "orderid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "linenumber": {
                        "description": "Position of this line on its document, starting at 1.",
                        "type": "integer"
                    },
                    "qtyorder": {
                        "type": "string",
                        "x-qty": true
                    },
                    "priceach": {
                        "type": "string",
                        "x-money": true
                    },
                    "ordertotal": {
                        "description": "Stored as `decimal(19,4)`.",
                        "type": "string",
                        "x-money": true
                    },
                    "committed": {
                        "description": "Allocated to open orders.",
                        "type": "boolean"
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "PurchaseorderlineCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "purchaseorderid": {
                        "description": "The PO to add to. Refused once it is complete or has receipts.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "linenumber": {
                        "description": "Position of this line on its document, starting at 1.",
                        "type": "integer"
                    },
                    "itemqty": {
                        "type": "string",
                        "x-qty": true
                    },
                    "itemprice": {
                        "type": "string",
                        "x-money": true
                    },
                    "pototal": {
                        "description": "Stored as `decimal(19,6)`.",
                        "type": "string",
                        "x-money": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "ApbilllineCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "apbillid": {
                        "description": "Apbillid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "glaccountid": {
                        "description": "Reference to `glaccounts`, by id. Write either this or `glaccount`.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true
                    },
                    "billtotal": {
                        "description": "Stored as `decimal(12,2)`.",
                        "type": "string",
                        "x-money": true
                    },
                    "distributed": {
                        "type": "string",
                        "x-money": true
                    },
                    "undistributed": {
                        "type": "string",
                        "x-money": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "OrderdepositCreated": {
                "type": "object",
                "properties": {
                    "id": {
                        "description": "NolaPro id.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "orderid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "amount": {
                        "type": "string",
                        "x-money": true
                    },
                    "voucherid": {
                        "description": "Voucherid. Id only.",
                        "type": "integer",
                        "x-idonly": true
                    },
                    "ondeposit": {
                        "type": "string",
                        "x-money": true
                    },
                    "ordertotal": {
                        "description": "Stored as `decimal(19,4)`.",
                        "type": "string",
                        "x-money": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "InvoiceRunResult": {
                "type": "object",
                "properties": {
                    "orderid": {
                        "type": "integer",
                        "x-idonly": true
                    },
                    "invoices": {
                        "type": "array",
                        "items": {
                            "type": "object"
                        }
                    },
                    "notices": {
                        "type": "string",
                        "x-unbounded": true
                    },
                    "_meta": {
                        "type": "object",
                        "description": "Present only when there is a warning to report. See Conventions."
                    }
                }
            },
            "InvoicelinesAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "description": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 255
                    },
                    "qty": {
                        "type": "string",
                        "description": "Quantity. Re-derives the invoice total. Decimal STRING.",
                        "x-qty": true,
                        "example": "3.000000"
                    },
                    "priceach": {
                        "type": "string",
                        "description": "Unit price. Re-derives the parent total. Decimal STRING.",
                        "x-money": true,
                        "example": "12.5000"
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "OrdersAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "ponumber": {
                        "type": "string",
                        "description": "The customer's own PO reference.",
                        "maxLength": 30
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "When payment or delivery is expected."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    },
                    "statusid": {
                        "type": "integer",
                        "description": "Service status, by id from GET /orderstatusoptions. Service orders only - no other order type carries the field. 0 clears it. Locked once the order is cancelled or fully billed, exactly as the service order screen locks it.",
                        "x-sibling": "statusoption"
                    },
                    "statusoption": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Service status by NAME instead of id (\"Order Complete\"). Exact match, trimmed, case-insensitive, against this company's statuses. Send either spelling; both get the same validation."
                    }
                },
                "additionalProperties": false
            },
            "OrderlinesAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "description": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 255
                    },
                    "qtyorder": {
                        "type": "string",
                        "description": "Quantity ordered. Re-derives the order total and re-commits stock. Decimal STRING.",
                        "x-qty": true,
                        "example": "3.000000"
                    },
                    "priceach": {
                        "type": "string",
                        "description": "Unit price. Re-derives the parent total. Decimal STRING.",
                        "x-money": true,
                        "example": "12.5000"
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "ShipmentsAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "carrierserviceid": {
                        "type": "integer",
                        "description": "Carrier service the shipment goes out by.",
                        "x-idonly": true
                    },
                    "shipdate": {
                        "type": "string",
                        "format": "date",
                        "description": "When it went out."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "PaymentsAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "reference": {
                        "type": "string",
                        "description": "Cheque number or transaction reference.",
                        "maxLength": 100
                    },
                    "method": {
                        "type": "integer",
                        "description": "Payment method id.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "PurchaseordersAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "When payment or delivery is expected."
                    },
                    "description": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 255
                    },
                    "notes": {
                        "type": "string",
                        "description": "Longer notes.",
                        "maxLength": 500
                    },
                    "requisition": {
                        "type": "string",
                        "description": "Requisition reference.",
                        "maxLength": 22
                    },
                    "ordernumber": {
                        "type": "string",
                        "description": "Your order number.",
                        "maxLength": 20
                    },
                    "tracknumber": {
                        "type": "string",
                        "description": "Carrier tracking number.",
                        "maxLength": 255
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "PurchaseorderlinesAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "description": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 255
                    },
                    "itemqty": {
                        "type": "string",
                        "description": "Quantity. Re-derives the PO total. Decimal STRING.",
                        "x-qty": true,
                        "example": "3.000000"
                    },
                    "itemprice": {
                        "type": "string",
                        "description": "Unit price. Re-derives the PO total. Decimal STRING.",
                        "x-money": true,
                        "example": "12.5000"
                    },
                    "notes": {
                        "type": "string",
                        "description": "Longer notes.",
                        "maxLength": 500
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "ApbillsAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "number": {
                        "type": "string",
                        "description": "The vendor's invoice number.",
                        "maxLength": 20
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "When payment or delivery is expected."
                    },
                    "date": {
                        "type": "string",
                        "format": "date",
                        "description": "Document date."
                    },
                    "description": {
                        "type": "string",
                        "description": "Free text.",
                        "maxLength": 255
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "ApbilllinesAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "amount": {
                        "type": "string",
                        "description": "How much codes to this account. Decimal STRING.",
                        "x-money": true,
                        "example": "12.5000"
                    },
                    "glaccountid": {
                        "type": "integer",
                        "description": "Account this line codes to.",
                        "x-idonly": true
                    },
                    "jobid": {
                        "type": "integer",
                        "description": "Job to cost this to.",
                        "x-idonly": true
                    },
                    "costcodeid": {
                        "type": "integer",
                        "description": "Cost code.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "OrderdepositsAmend": {
                "type": "object",
                "description": "Only the fields this document has not already acted on. Sending anything else returns 422 and names what is still amendable.",
                "properties": {
                    "reference": {
                        "type": "string",
                        "description": "Cheque number or transaction reference.",
                        "maxLength": 100
                    },
                    "method": {
                        "type": "integer",
                        "description": "Payment method id.",
                        "x-idonly": true
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "InvoicesAmend": {
                "type": "object",
                "description": "What an invoice will still accept depends on whether it is posted. `ponumber` is a reference the customer gave you and is amendable either way. `duedate` closes once the invoice posts, because AR aging is built from it. Amounts and lines are never amendable - credit the invoice and raise another, which is what leaves a trail.",
                "properties": {
                    "ponumber": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The customer's own PO reference. Amendable whatever the invoice has done."
                    },
                    "duedate": {
                        "type": "string",
                        "format": "date",
                        "description": "When payment is expected. **Unposted invoices only** - returns 422 once posted."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own identifier for this record."
                    }
                },
                "additionalProperties": false
            },
            "GlTransactionCancelled": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The voucher id."
                    },
                    "voucher": {
                        "type": "string",
                        "maxLength": 30,
                        "description": "The voucher number."
                    },
                    "cancelled": {
                        "type": "boolean",
                        "description": "The voucher is now cancelled."
                    },
                    "unposted": {
                        "type": "boolean",
                        "description": "It was posted and has been reversed. **False means it was never posted**, not that the reversal failed."
                    },
                    "lines": {
                        "type": "integer",
                        "description": "How many GL lines the voucher now carries."
                    }
                }
            },
            "WebhookCreated": {
                "type": "object",
                "description": "The new subscription. This is the only response that ever carries `secret` - it is not stored in retrievable form and cannot be looked up later.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "url": {
                        "type": "string",
                        "maxLength": 500,
                        "description": "HTTPS endpoint to POST to. Plain HTTP is refused - the payload carries business data and the signature is worthless over a channel anyone can read."
                    },
                    "events": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        },
                        "description": "Event types to receive. `*` is not accepted: naming them is what stops a new event type silently appearing in your handler."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "What this subscription is for. Shown on the token screen."
                    },
                    "paused": {
                        "type": "boolean",
                        "description": "Pause delivery without cancelling the subscription. A paused subscription drops events rather than queueing them - it is a tap, not a buffer. Deliberately not called `active`: D23 reserves that word, and `cancel` already means something else here."
                    },
                    "failcount": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "Consecutive failed deliveries. Resets on the first success."
                    },
                    "lastdeliverydate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Last successful delivery."
                    },
                    "disableddate": {
                        "type": "string",
                        "format": "date-time",
                        "readOnly": true,
                        "description": "Set when we gave up. See the disabling rule in Webhooks."
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled."
                    },
                    "secret": {
                        "type": "string",
                        "description": "The HMAC-SHA256 signing secret, 64 hex characters. Returned once, here. Store it before you acknowledge the call.",
                        "x-envelope": true
                    },
                    "secret_note": {
                        "type": "string",
                        "description": "A plain-language reminder that the secret is not returned again.",
                        "x-envelope": true
                    }
                }
            },
            "RequestLogEntry": {
                "type": "object",
                "description": "One request this token made. Written only while logging is enabled on the token, and only the last 100 are kept.",
                "properties": {
                    "requestid": {
                        "type": "string",
                        "maxLength": 36,
                        "description": "The `X-Request-Id` we returned. Quote it when you report a problem.",
                        "x-example": "9f2c1b7a-4d10-4a6e-9f31-2b8c5e77a010"
                    },
                    "method": {
                        "type": "string",
                        "maxLength": 10,
                        "x-example": "POST"
                    },
                    "route": {
                        "type": "string",
                        "maxLength": 255,
                        "description": "The matched route PATTERN, never the URI you sent. Ids and query values are deliberately not recorded.",
                        "x-example": "/api/v2/invoices/{id}"
                    },
                    "httpstatus": {
                        "type": "integer",
                        "x-example": 422
                    },
                    "errorcode": {
                        "type": "string",
                        "maxLength": 40,
                        "description": "Empty when the request succeeded.",
                        "x-example": "closed_period"
                    },
                    "durationms": {
                        "type": "integer",
                        "description": "Server time, not round trip.",
                        "x-example": 84
                    },
                    "bytesin": {
                        "type": "integer",
                        "x-example": 612
                    },
                    "bytesout": {
                        "type": "integer",
                        "x-example": 1840
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "x-example": "2026-08-02T14:22:05Z"
                    }
                }
            },
            "WebhookFlushResult": {
                "type": "object",
                "description": "What the immediate delivery run did.",
                "properties": {
                    "sent": {
                        "type": "integer",
                        "description": "Events delivered and acknowledged.",
                        "x-example": 4
                    },
                    "failed": {
                        "type": "integer",
                        "description": "Attempts that failed. Delivery stops at the first one, so this is 0 or 1.",
                        "x-example": 0
                    },
                    "pending": {
                        "type": "integer",
                        "description": "Still owed after the run, including anything behind a failure.",
                        "x-example": 0
                    }
                }
            },
            "WebhookDelivery": {
                "type": "object",
                "description": "One attempt to deliver one event to one subscription.",
                "properties": {
                    "eventid": {
                        "type": "string",
                        "maxLength": 40,
                        "description": "The envelope id, stable across every retry of the same event.",
                        "x-example": "evt_01J8ZQ4M2K7X"
                    },
                    "eventtype": {
                        "type": "string",
                        "maxLength": 60,
                        "x-example": "orders.created"
                    },
                    "attempts": {
                        "type": "integer",
                        "description": "How many times this event has been tried.",
                        "x-example": 1
                    },
                    "delivered": {
                        "type": "boolean",
                        "description": "True once your endpoint answered 2xx.",
                        "x-example": true
                    },
                    "abandoned": {
                        "type": "boolean",
                        "description": "True when the attempts ran out and the event was dropped. It will never be retried.",
                        "x-example": false,
                        "x-synthetic": true
                    },
                    "responsecode": {
                        "type": "integer",
                        "description": "What your endpoint answered. 0 means we never reached it.",
                        "x-example": 200
                    },
                    "responsebody": {
                        "type": "string",
                        "maxLength": 500,
                        "description": "The first 500 bytes your endpoint returned. Usually where the real error is.",
                        "x-example": ""
                    },
                    "durationms": {
                        "type": "integer",
                        "description": "Round trip, ours to yours and back.",
                        "x-example": 84
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "x-example": "2026-08-02T14:22:05Z"
                    },
                    "nextattemptdate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the next attempt is due. Null once delivered or abandoned."
                    }
                }
            },
            "WebhookRotated": {
                "allOf": [
                    {
                        "$ref": "#/components/schemas/RefWebhooks"
                    },
                    {
                        "type": "object",
                        "properties": {
                            "secret": {
                                "type": "string",
                                "description": "The new signing secret. Returned once, here and nowhere else.",
                                "x-example": "9c1f..."
                            },
                            "previoussecretvaliduntil": {
                                "type": "string",
                                "format": "date-time",
                                "description": "When the old secret stops being accepted. Null when you rotated with `immediate`.",
                                "x-synthetic": true
                            }
                        }
                    }
                ]
            },
            "RefOrderstatusoptions": {
                "type": "object",
                "description": "Custom service order statuses (\"In Progress\", \"Waiting for Parts\", \"Order Complete\"...). Referenced by `statusid` on a service order; `complete` marks the statuses that mean the work is done.",
                "properties": {
                    "id": {
                        "type": "integer",
                        "readOnly": true,
                        "description": "NolaPro id."
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "The status name shown on the service order screen (\"Waiting for Parts\", \"Order Complete\")."
                    },
                    "sortorder": {
                        "type": "integer",
                        "description": "Display order in the status dropdown, low first."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the status option was created.",
                        "readOnly": true
                    },
                    "lastchangedate": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Last modification. Drives `modifiedsince`.",
                        "readOnly": true
                    },
                    "cancel": {
                        "type": "boolean",
                        "description": "Cancelled. Always a boolean on the wire, whatever integer width the column uses (D23)."
                    },
                    "complete": {
                        "type": "boolean",
                        "description": "This status means the work is done. The order list treats an order carrying a complete status as finished."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                }
            },
            "ServiceordertimesAmend": {
                "type": "object",
                "description": "Only while the entry is unbilled (status below 2, else 409 hours_already_billed). The worker and work type are the entry's identity and cannot be amended - cancel the entry and log a new one. Totals re-derive from whatever the row ends up holding. A rate sent here is stored as sent.",
                "properties": {
                    "worksubtypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "Optional sub-classification. Must belong to worktypeid."
                    },
                    "hours": {
                        "type": "string",
                        "x-qty": true,
                        "x-decimals": 2,
                        "description": "Hours worked, 2 decimal places, as a string. Negative is a correction. Zero is allowed only with a note - the entry stays a placeholder (status 0) and never bills."
                    },
                    "entrydate": {
                        "type": "string",
                        "format": "date",
                        "description": "The date the work was done. Defaults to today."
                    },
                    "rate": {
                        "type": "string",
                        "x-money": true,
                        "x-decimals": 4,
                        "description": "The billing rate per hour, in the ORDER currency. When omitted it derives from the work class rate for the worker, converted at the order date, times the pay type multiplier. When sent it is stored as sent - the multiplier is not applied on top."
                    },
                    "costrate": {
                        "type": "string",
                        "x-money": true,
                        "x-decimals": 4,
                        "description": "Cost per hour to the company, in the company BASE currency. When omitted it derives from the worker: fringe-loaded pay for an employee, default cost per hour for a vendor."
                    },
                    "notes": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Customer-visible notes. Concatenated onto the invoice line when hours convert."
                    },
                    "internal_comment": {
                        "type": "string",
                        "x-unbounded": true,
                        "description": "Internal notes. Never shown to the customer."
                    },
                    "techname": {
                        "type": "string",
                        "maxLength": 50,
                        "description": "Technician name override. Defaults from the worker."
                    },
                    "taxclassid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "Tax class, when labor is taxable."
                    },
                    "assetid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "The customer asset being serviced."
                    },
                    "prpaytypeid": {
                        "type": "integer",
                        "x-idonly": true,
                        "description": "AR pay type (straight time, overtime...). Only pay types flagged for AR are accepted - the screen offers no others."
                    },
                    "prpaytypemultiplier": {
                        "type": "string",
                        "x-number": true,
                        "x-decimals": 2,
                        "description": "Rate multiplier. Defaults to the pay type's own multiplier, else 1.00. Applied only when rate is derived."
                    },
                    "startdatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Timer start, for entries imported from a timer."
                    },
                    "enddatetime": {
                        "type": "string",
                        "format": "date-time",
                        "description": "Timer stop."
                    },
                    "externalid": {
                        "type": "string",
                        "maxLength": 100,
                        "description": "Your own key. Scoped to your company."
                    }
                },
                "additionalProperties": false
            }
        },
        "parameters": {
            "IdempotencyKey": {
                "name": "Idempotency-Key",
                "in": "header",
                "required": false,
                "schema": {
                    "type": "string",
                    "maxLength": 255
                },
                "description": "Makes the write safely retryable. Any unique string per logical operation; a UUID is fine.\n\nThe failure this prevents is specific: the request succeeds, the response is lost to a timeout, you retry, and the customer is billed twice. With a key, the retry returns the **original** response - same status, same body, same id - and creates nothing.\n\nThe body is part of the key's identity. Reusing a key with a *different* body is a bug on your side, not a retry, and answers `409 idempotency_replay` rather than silently handing back the old response. Keys are remembered for 24 hours."
            }
        }
    },
    "webhooks": {
        "customers.created": {
            "post": {
                "summary": "A customer was created.",
                "description": "A customer was created.\n\nRequires `customers:read` on the token that owns the subscription.\n\nWanted by: StoreBridge, Reclaim.",
                "x-scope": "customers:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "customers.updated": {
            "post": {
                "summary": "A customer changed. Includes credit limit and hold status.",
                "description": "A customer changed. Includes credit limit and hold status.\n\nRequires `customers:read` on the token that owns the subscription.\n\nWanted by: Reclaim, AccountView.",
                "x-scope": "customers:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "customers.cancelled": {
            "post": {
                "summary": "A customer was cancelled.",
                "description": "A customer was cancelled.\n\nRequires `customers:read` on the token that owns the subscription.\n\nWanted by: StoreBridge.",
                "x-scope": "customers:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "orders.created": {
            "post": {
                "summary": "An order, quote or service order was created.",
                "description": "An order, quote or service order was created.\n\nRequires `orders:read` on the token that owns the subscription.\n\nWanted by: DockHand, FieldKit, TradeLink.",
                "x-scope": "orders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "orders.updated": {
            "post": {
                "summary": "An order header or any of its lines changed. Fires once for the order, not per line.",
                "description": "An order header or any of its lines changed. Fires once for the order, not per line.\n\nRequires `orders:read` on the token that owns the subscription.\n\nWanted by: DockHand, QuoteSmith.",
                "x-scope": "orders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "orders.cancelled": {
            "post": {
                "summary": "An order was cancelled. Committed stock has been released.",
                "description": "An order was cancelled. Committed stock has been released.\n\nRequires `orders:read` on the token that owns the subscription.\n\nWanted by: StoreBridge, DockHand.",
                "x-scope": "orders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "orders.invoiced": {
            "post": {
                "summary": "An order produced one or more invoices.",
                "description": "An order produced one or more invoices.\n\nRequires `invoices:read` on the token that owns the subscription.\n\nWanted by: StoreBridge, AccountView.",
                "x-scope": "invoices:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "shipments.created": {
            "post": {
                "summary": "A shipment went out. The 856 trigger.",
                "description": "A shipment went out. The 856 trigger.\n\nRequires `shipments:read` on the token that owns the subscription.\n\nWanted by: StoreBridge, TradeLink, AccountView.",
                "x-scope": "shipments:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "shipments.cancelled": {
            "post": {
                "summary": "A shipment was cancelled and its stock movement reversed.",
                "description": "A shipment was cancelled and its stock movement reversed.\n\nRequires `shipments:read` on the token that owns the subscription.\n\nWanted by: StoreBridge.",
                "x-scope": "shipments:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "invoices.posted": {
            "post": {
                "summary": "An invoice posted to the ledger. The 810 trigger.",
                "description": "An invoice posted to the ledger. The 810 trigger.\n\nRequires `invoices:read` on the token that owns the subscription.\n\nWanted by: TradeLink, Reclaim, AccountView.",
                "x-scope": "invoices:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "invoices.cancelled": {
            "post": {
                "summary": "An invoice was cancelled.",
                "description": "An invoice was cancelled.\n\nRequires `invoices:read` on the token that owns the subscription.\n\nWanted by: Reclaim.",
                "x-scope": "invoices:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "payments.created": {
            "post": {
                "summary": "A payment was applied to an invoice.",
                "description": "A payment was applied to an invoice.\n\nRequires `payments:read` on the token that owns the subscription.\n\nWanted by: Reclaim, AccountView.",
                "x-scope": "payments:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "payments.cancelled": {
            "post": {
                "summary": "A payment was reversed.",
                "description": "A payment was reversed.\n\nRequires `payments:read` on the token that owns the subscription.\n\nWanted by: Reclaim.",
                "x-scope": "payments:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "orderdeposits.created": {
            "post": {
                "summary": "A deposit was taken against an order.",
                "description": "A deposit was taken against an order.\n\nRequires `payments:read` on the token that owns the subscription.\n\nWanted by: Reclaim.",
                "x-scope": "payments:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "purchaseorders.created": {
            "post": {
                "summary": "A purchase order was raised.",
                "description": "A purchase order was raised.\n\nRequires `purchaseorders:read` on the token that owns the subscription.\n\nWanted by: SupplyDesk.",
                "x-scope": "purchaseorders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "purchaseorders.updated": {
            "post": {
                "summary": "A purchase order or one of its lines changed.",
                "description": "A purchase order or one of its lines changed.\n\nRequires `purchaseorders:read` on the token that owns the subscription.\n\nWanted by: SupplyDesk.",
                "x-scope": "purchaseorders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "purchaseorders.cancelled": {
            "post": {
                "summary": "A purchase order was cancelled.",
                "description": "A purchase order was cancelled.\n\nRequires `purchaseorders:read` on the token that owns the subscription.\n\nWanted by: SupplyDesk.",
                "x-scope": "purchaseorders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "invreceives.created": {
            "post": {
                "summary": "Goods were received against a purchase order.",
                "description": "Goods were received against a purchase order.\n\nRequires `purchaseorders:read` on the token that owns the subscription.\n\nWanted by: SupplyDesk, DockHand.",
                "x-scope": "purchaseorders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "items.created": {
            "post": {
                "summary": "An item was created.",
                "description": "An item was created.\n\nRequires `items:read` on the token that owns the subscription.\n\nWanted by: StoreBridge.",
                "x-scope": "items:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "items.updated": {
            "post": {
                "summary": "An item changed. Price and description changes land here.",
                "description": "An item changed. Price and description changes land here.\n\nRequires `items:read` on the token that owns the subscription.\n\nWanted by: StoreBridge.",
                "x-scope": "items:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "items.stockchanged": {
            "post": {
                "summary": "On-hand or available quantity moved at a location. **High volume** - subscribe only if you mirror stock.",
                "description": "On-hand or available quantity moved at a location. **High volume** - subscribe only if you mirror stock.\n\nRequires `items:read` on the token that owns the subscription.\n\nWanted by: StoreBridge, DockHand.",
                "x-scope": "items:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "serviceordertimes.billed": {
            "post": {
                "summary": "Logged hours were converted to order lines and billed.",
                "description": "Logged hours were converted to order lines and billed.\n\nRequires `orders:read` on the token that owns the subscription.\n\nWanted by: FieldKit, ClockFeed.",
                "x-scope": "orders:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it. Answer within 10 seconds and do the real work afterwards - we retry a timeout, and a slow handler turns one event into five."
                    },
                    "410": {
                        "description": "Tells us this subscription is dead and we disable it immediately rather than retrying for two days."
                    }
                }
            }
        },
        "itemidentifierdetails.created": {
            "post": {
                "summary": "A serial number, lot or expiry value was recorded against an item.",
                "description": "A serial number, lot or expiry value was recorded against an item.\n\nRequires `items:read` on the token that owns the subscription.\n\nAdded because `itemidentifierdetail` has no auto-maintained `lastchangedate`, so it cannot be delta-polled until that is fixed (see the deferred section in the plan). A webhook fires on write and needs no such column, so this closes the gap now rather than later.\n\nWanted by: DockHand.",
                "x-scope": "items:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it."
                    },
                    "410": {
                        "description": "Disables the subscription immediately."
                    }
                }
            }
        },
        "itemidentifierdetails.updated": {
            "post": {
                "summary": "An identifier value changed, including its on-hand quantity at a location.",
                "description": "An identifier value changed, including its on-hand quantity at a location.\n\nRequires `items:read` on the token that owns the subscription.\n\nAdded because `itemidentifierdetail` has no auto-maintained `lastchangedate`, so it cannot be delta-polled until that is fixed (see the deferred section in the plan). A webhook fires on write and needs no such column, so this closes the gap now rather than later.\n\nWanted by: DockHand.",
                "x-scope": "items:read",
                "x-status": "planned",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/RefWebhookEvent"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Any 2xx means you accepted it."
                    },
                    "410": {
                        "description": "Disables the subscription immediately."
                    }
                }
            }
        }
    }
}
