{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "#/components/schemas/Account", "title": "Account", "type": "object", "externalDocs": { "url": "http://developer.xero.com/documentation/api/accounts/" }, "properties": { "Code": { "description": "Customer defined alpha numeric account code e.g 200 or SALES (max length = 10)", "type": "string", "example": 4400 }, "Name": { "description": "Name of account (max length = 150)", "maxLength": 150, "type": "string", "example": "Food Sales" }, "AccountID": { "description": "The Xero identifier for an account \u2013 specified as a string following the endpoint name e.g. /297c2dc5-cc47-4afd-8ec8-74990b8761e9", "type": "string", "format": "uuid", "example": "00000000-0000-0000-0000-000000000000" }, "Type": { "$ref": "#/components/schemas/AccountType", "type": "string" }, "BankAccountNumber": { "description": "For bank accounts only (Account Type BANK)", "type": "string" }, "Status": { "description": "Accounts with a status of ACTIVE can be updated to ARCHIVED. See Account Status Codes", "type": "string", "enum": [ "ACTIVE", "ARCHIVED", "DELETED" ] }, "Description": { "description": "Description of the Account. Valid for all types of accounts except bank accounts (max length = 4000)", "type": "string" }, "BankAccountType": { "description": "For bank accounts only. See Bank Account types", "type": "string", "enum": [ "BANK", "CREDITCARD", "PAYPAL", "NONE", "" ] }, "CurrencyCode": { "$ref": "#/components/schemas/CurrencyCode", "type": "string" }, "TaxType": { "description": "The tax type from taxRates", "type": "string" }, "EnablePaymentsToAccount": { "description": "Boolean \u2013 describes whether account can have payments applied to it", "type": "boolean" }, "ShowInExpenseClaims": { "description": "Boolean \u2013 describes whether account code is available for use with expense claims", "type": "boolean" }, "Class": { "description": "See Account Class Types", "readOnly": true, "type": "string", "enum": [ "ASSET", "EQUITY", "EXPENSE", "LIABILITY", "REVENUE" ] }, "SystemAccount": { "description": "If this is a system account then this element is returned. See System Account types. Note that non-system accounts may have this element set as either \u201c\u201d or null.", "readOnly": true, "type": "string", "enum": [ "DEBTORS", "CREDITORS", "BANKCURRENCYGAIN", "GST", "GSTONIMPORTS", "HISTORICAL", "REALISEDCURRENCYGAIN", "RETAINEDEARNINGS", "ROUNDING", "TRACKINGTRANSFERS", "UNPAIDEXPCLM", "UNREALISEDCURRENCYGAIN", "WAGEPAYABLES", "CISASSETS", "CISASSET", "CISLABOUR", "CISLABOUREXPENSE", "CISLABOURINCOME", "CISLIABILITY", "CISMATERIALS", "" ] }, "ReportingCode": { "description": "Shown if set", "type": "string" }, "ReportingCodeName": { "description": "Shown if set", "readOnly": true, "type": "string" }, "HasAttachments": { "description": "boolean to indicate if an account has an attachment (read only)", "readOnly": true, "type": "boolean", "default": "false", "example": "false" }, "UpdatedDateUTC": { "description": "Last modified date UTC format", "type": "string", "x-is-msdate-time": true, "example": "/Date(1573755038314)/", "readOnly": true }, "AddToWatchlist": { "description": "Boolean \u2013 describes whether the account is shown in the watchlist widget on the dashboard", "type": "boolean" }, "ValidationErrors": { "description": "Displays array of validation error messages from the API", "type": "array", "items": { "$ref": "#/components/schemas/ValidationError" } } } }