{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/quickbooks/json-schema/quickbooks-accountrequest-schema.json",
  "title": "accountrequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/quickbooks-account-api-openapi.yml#/components/schemas/accountrequest",
  "type": "object",
  "properties": {
    "AcctNum": {
      "type": "string",
      "description": "User-defined account number to help the user in identifying the account within the chart-of-accounts and in deciding what should be posted to the account. The Account.AcctNum attribute must not contain colon (:).",
      "x-intuit-required": "Conditionally required"
    },
    "TaxCodeRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to the default tax code used by this account. Tax codes are referenced by the TaxCode.Id in the TaxCode object. For global locales, only.",
      "x-intuit-required": "Conditionally required"
    },
    "Name": {
      "type": "string",
      "description": "User recognizable name for the Account.\nAccount.Name attribute must not contain double quotes (\") or colon (:).",
      "x-intuit-required": "Required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "AccountType": {
      "type": "string",
      "description": "A detailed account classification that specifies the use of this account. The type is based on the Classification.\n\n Required if AccountSubType is not specified.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true
    },
    "AccountSubType": {
      "type": "string",
      "description": "The account sub-type classification and is based on the AccountType value.\n\n Required if AccountType is not specified.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true
    }
  },
  "required": [
    "Name"
  ],
  "$defs": {
    "referencetype": {
      "type": "object",
      "title": "referencetype",
      "properties": {
        "name": {
          "type": "string",
          "description": "An identifying name for the object being referenced by value and is derived from the field that holds the common name of that object. This varies by context and specific type of object referenced. For example, references to a Customer object use Customer.DisplayName to populate this field. Optionally returned in responses, implementation dependent.",
          "x-intuit-required": "Optional"
        },
        "value": {
          "type": "string",
          "description": "The ID for the referenced object as found in the Id field of the object payload. The context is set by the type of reference and is specific to the QuickBooks company file.",
          "x-intuit-required": "Required"
        }
      },
      "required": [
        "value"
      ]
    }
  }
}