{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/quickbooks/json-schema/quickbooks-customerresponse-schema.json",
  "title": "customerresponse",
  "x-generated": "2026-11-05",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/quickbooks-online-accounting-openapi-generated.yml#/components/schemas/customerresponse",
  "type": "object",
  "properties": {
    "PrimaryEmailAddr": {
      "allOf": [
        {
          "$ref": "#/$defs/emailaddress"
        }
      ],
      "description": "Primary email address.",
      "x-intuit-required": "Optional",
      "x-intuit-filterable": true
    },
    "DisplayName": {
      "type": "string",
      "description": "The name of the person or organization as displayed. Must be unique across all Customer, Vendor, and Employee objects. Cannot be removed with sparse update.\nIf not supplied, the system generates DisplayName by concatenating customer name components supplied in the request from the following list: Title, GivenName, MiddleName, FamilyName, and Suffix.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "Title": {
      "type": "string",
      "description": "Title of the person. This tag supports i18n, all locales. The DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, or Suffix attributes is required.",
      "x-intuit-required": "Conditionally required"
    },
    "ResaleNum": {
      "type": "string",
      "description": "Resale number or some additional info about the customer.",
      "x-intuit-required": "Optional"
    },
    "SecondaryTaxIdentifier": {
      "type": "string",
      "description": "Also called UTR No. in ( UK ) , CST Reg No. ( IN ) also represents the tax registration number of the Person or Organization. This value is masked in responses, exposing only last five characters. For example, the ID of 123-45-6789 is returned as XXXXXX56789.",
      "x-intuit-required": "Optional"
    },
    "DefaultTaxCodeRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to a default tax code associated with this Customer object. Reference is valid if Customer.Taxable is set to true; otherwise, it is ignored.\nIf automated sales tax is enabled (Preferences.TaxPrefs.PartnerTaxEnabled is set to true) the default tax code is set by the system and can not be overridden.\nQuery the TaxCode name list resource to determine the appropriate TaxCode object for this reference. Use TaxCode.Id and TaxCode.Name from that object for DefaultTaxCodeRef.value and DefaultTaxCodeRef.name, respectively.",
      "x-intuit-required": "Optional"
    },
    "PreferredDeliveryMethod": {
      "type": "string",
      "description": "Preferred delivery method. Values are Print, Email, or None.",
      "x-intuit-required": "Optional"
    },
    "GivenName": {
      "type": "string",
      "description": "Given name or first name of a person. The DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, or Suffix attributes is required.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "SalesTermRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to a SalesTerm associated with this Customer object. Query the Term name list resource to determine the appropriate Term object for this reference. Use Term.Id and Term.Name from that object for SalesTermRef.value and SalesTermRef.name, respectively.",
      "x-intuit-required": "Optional"
    },
    "CustomerTypeRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to the customer type assigned to a customer. This field is only returned if the customer is assigned a customer type.",
      "x-intuit-required": "Optional"
    },
    "FullyQualifiedName": {
      "type": "string",
      "description": "Fully qualified name of the object. The fully qualified name prepends the topmost parent, followed by each sub element separated by colons. Takes the form of\nCustomer:Job:Sub-job. System generated. Limited to 5 levels.",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "Fax": {
      "allOf": [
        {
          "$ref": "#/$defs/telephonenumber"
        }
      ],
      "description": "Fax number.",
      "x-intuit-required": "Optional"
    },
    "BillWithParent": {
      "type": "boolean",
      "description": "If true, this Customer object is billed with its parent. If false, or null the customer is not to be billed with its parent. This attribute is valid only if this entity is a Job or sub Customer.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "false"
    },
    "CurrencyRef": {
      "allOf": [
        {
          "$ref": "#/$defs/currencyref"
        }
      ],
      "description": "Reference to the currency in which all amounts associated with this customer are expressed. Once set, it cannot be changed.\nIf specified currency is not currently in the company's currency list, it is added.\nIf not specified, currency for this customer is the home currency of the company, as defined by Preferences.CurrencyPrefs.HomeCurrency.",
      "x-intuit-required": "Optional"
    },
    "Mobile": {
      "allOf": [
        {
          "$ref": "#/$defs/telephonenumber"
        }
      ],
      "description": "Mobile phone number.",
      "x-intuit-required": "Optional"
    },
    "Job": {
      "type": "boolean",
      "description": "If true, this is a Job or sub-customer. If false or null, this is a top level customer, not a Job or sub-customer.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "false or null"
    },
    "BalanceWithJobs": {
      "type": "number",
      "description": "Cumulative open balance amount for the Customer (or Job) and all its sub-jobs. Cannot be written to QuickBooks.",
      "x-intuit-required": "Optional",
      "x-intuit-sortable": true
    },
    "PrimaryPhone": {
      "allOf": [
        {
          "$ref": "#/$defs/telephonenumber"
        }
      ],
      "description": "Primary phone number.",
      "x-intuit-required": "Optional"
    },
    "OpenBalanceDate": {
      "type": "string",
      "format": "date",
      "description": "Date of the Open Balance for the create operation. Write-on-create.",
      "x-intuit-required": "Optional"
    },
    "Taxable": {
      "type": "boolean",
      "description": "If true, transactions for this customer are taxable.\nDefault behavior: true, if DefaultTaxCodeRef is defined or false if TaxExemptionReasonId is set.",
      "x-intuit-required": "Optional"
    },
    "AlternatePhone": {
      "allOf": [
        {
          "$ref": "#/$defs/telephonenumber"
        }
      ],
      "description": "Alternate phone number.",
      "x-intuit-required": "Optional"
    },
    "MetaData": {
      "allOf": [
        {
          "$ref": "#/$defs/modificationmetadata"
        }
      ],
      "description": "Descriptive information about the entity. The MetaData values are set by Data Services and are read only for all applications.",
      "x-intuit-required": "Optional"
    },
    "ParentRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "A reference to a Customer object that is the immediate parent of the Sub-Customer/Job in the hierarchical Customer:Job list.\nRequired for the create operation if this object is a sub-customer or Job. Query the Customer name list resource to determine the appropriate Customer object for this reference. Use Customer.Id and Customer.DisplayName from that object for ParentRef.value and ParentRef.name, respectively.",
      "x-intuit-required": "Optional"
    },
    "Level": {
      "type": "integer",
      "description": "Specifies the level of the hierarchy in which the entity is located. Zero specifies the top level of the hierarchy; anything above will be level with respect to the parent.\n\nConstraints:up to 5 levels",
      "x-intuit-default": "0"
    },
    "MiddleName": {
      "type": "string",
      "description": "Middle name of the person. The person can have zero or more middle names. The DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, or Suffix attributes is required.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "Notes": {
      "type": "string",
      "description": "Free form text describing the Customer.",
      "x-intuit-required": "Optional"
    },
    "TaxExemptionReasonId": {
      "type": "object",
      "x-intuit-type": "Numeric Id",
      "description": "The tax exemption reason associated with this customer object. Applicable if automated sales tax is enabled (Preferences.TaxPrefs.PartnerTaxEnabled is set to true) for the company. Set  TaxExemptionReasonId: to one of the following:\n\nId\nReason\n\n1\nFederal government\n\n2\nState government\n\n3\nLocal government\n\n4\nTribal government\n\n5\nCharitable organization\n\n6\nReligious organization\n\n7\nEducational organization\n\n8\nHospital\n\n9\nResale\n\n10\nDirect pay permit\n\n11\nMultiple points of use\n\n12\nDirect mail\n\n13\nAgricultural production\n\n14\nIndustrial production / manufacturing\n\n15\nForeign diplomat"
    },
    "WebAddr": {
      "allOf": [
        {
          "$ref": "#/$defs/websiteaddress"
        }
      ],
      "description": "Website address.",
      "x-intuit-required": "Optional"
    },
    "Active": {
      "type": "boolean",
      "description": "If true, this entity is currently enabled for use by QuickBooks. \nIf there is an amount in Customer.Balance when setting this Customer object to inactive through the QuickBooks UI, a CreditMemo balancing transaction is created for the amount.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "true",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "CompanyName": {
      "type": "string",
      "description": "The name of the company associated with the person or organization.",
      "x-intuit-required": "Optional",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "Balance": {
      "type": "number",
      "description": "Specifies the open balance amount or the amount unpaid by the customer. For the create operation, this represents the opening balance for the customer. When returned in response to the query request it represents the current open balance (unpaid amount) for that customer. Write-on-create.",
      "x-intuit-required": "Optional",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "SyncToken": {
      "type": "string",
      "description": "Version number of the object. It is used to lock an object for use by one app at a time. As soon as an application modifies an object, its SyncToken is incremented. Attempts to modify an object specifying an older SyncToken fails. Only the latest version of the object is maintained by QuickBooks Online.",
      "x-intuit-required": "Required for update"
    },
    "ShipAddr": {
      "allOf": [
        {
          "$ref": "#/$defs/physicaladdress"
        }
      ],
      "description": "Default shipping address. If a physical address is updated from within the transaction object, the QuickBooks Online API flows individual address components differently into the Line elements of the transaction response then when the transaction was first created:Line1 and Line2 elements are populated with the customer name and company name.\nOriginal Line1 through Line 5 contents, City, SubDivisionCode, and PostalCode flow into Line3 through Line5as a free format strings.",
      "x-intuit-required": "Optional"
    },
    "PaymentMethodRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to a PaymentMethod associated with this Customer object. Query the PaymentMethod name list resource to determine the appropriate PaymentMethod object for this reference. Use PaymentMethod.Id and PaymentMethod.Name from that object for PaymentMethodRef.value and PaymentMethodRef.name, respectively.",
      "x-intuit-required": "Optional"
    },
    "Suffix": {
      "type": "string",
      "description": "Suffix of the name. For example, Jr. The DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, or Suffix attributes is required.",
      "x-intuit-required": "Conditionally required"
    },
    "IsProject": {
      "type": "boolean",
      "description": "If true, indicates this is a Project.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "False or null"
    },
    "Source": {
      "type": "string",
      "description": "The Source type of the transactions created by QuickBooks Commerce. Valid values include: QBCommerce",
      "x-intuit-required": "Optional"
    },
    "FamilyName": {
      "type": "string",
      "description": "Family name or the last name of the person. The DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, or Suffix attributes is required.",
      "x-intuit-required": "Conditionally required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "PrimaryTaxIdentifier": {
      "type": "string",
      "description": "Also called Tax Reg. No in ( UK ) , ( CA ) , ( IN ) , ( AU ) represents the tax ID of the Person or Organization. This value is masked in responses, exposing only last five characters. For example, the ID of 123-45-6789 is returned as XXXXXX56789.",
      "x-intuit-required": "Optional"
    },
    "PrintOnCheckName": {
      "type": "string",
      "description": "Name of the person or organization as printed on a check. If not provided, this is populated from DisplayName.\n\nConstraints: Cannot be removed with sparse update.",
      "x-intuit-required": "Optional",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "BillAddr": {
      "allOf": [
        {
          "$ref": "#/$defs/physicaladdress"
        }
      ],
      "description": "Default billing address. If a physical address is updated from within the transaction object, the QuickBooks Online API flows individual address components differently into the Line elements of the transaction response then when the transaction was first created:Line1 and Line2 elements are populated with the customer name and company name.\nOriginal Line1 through Line 5 contents, City, SubDivisionCode, and PostalCode flow into Line3 through Line5as a free format strings.",
      "x-intuit-required": "Optional"
    },
    "Id": {
      "type": "string",
      "description": "Unique identifier for this object.",
      "x-intuit-required": "Required for update",
      "x-intuit-filterable": true
    }
  },
  "$defs": {
    "currencyref": {
      "type": "object",
      "title": "currencyref",
      "properties": {
        "name": {
          "type": "string",
          "description": "The full name of the currency.",
          "x-intuit-required": "Optional"
        },
        "value": {
          "type": "string",
          "description": "A three letter string representing the ISO 4217 code for the currency. For example, USD, AUD, EUR, and so on.",
          "x-intuit-required": "Required"
        }
      },
      "required": [
        "value"
      ]
    },
    "emailaddress": {
      "type": "object",
      "title": "emailaddress",
      "properties": {
        "Address": {
          "type": "string",
          "description": "An email address. The address format must follow the RFC 822 standard.",
          "x-intuit-required": "Optional"
        }
      }
    },
    "modificationmetadata": {
      "type": "object",
      "title": "modificationmetadata",
      "properties": {
        "CreateTime": {
          "type": "string",
          "format": "date-time",
          "description": "Time the entity was created in the source domain.",
          "x-intuit-filterable": true,
          "x-intuit-sortable": true
        },
        "LastUpdatedTime": {
          "type": "string",
          "format": "date-time",
          "description": "Time the entity was last updated in the source domain.",
          "x-intuit-filterable": true,
          "x-intuit-sortable": true
        }
      }
    },
    "physicaladdress": {
      "type": "object",
      "title": "physicaladdress",
      "properties": {
        "City": {
          "type": "string",
          "description": "City name.",
          "x-intuit-required": "Optional"
        },
        "Country": {
          "type": "string",
          "description": "For international addresses, the request can be an ISO alpha-3 code or the full name of the country. The response for update and read operations returns ISO alpha-3 country codes only.",
          "x-intuit-required": "Optional"
        },
        "Line5": {
          "type": "string",
          "description": "Fifth line of the address.",
          "x-intuit-required": "Optional"
        },
        "Line4": {
          "type": "string",
          "description": "Fourth line of the address.",
          "x-intuit-required": "Optional"
        },
        "Line3": {
          "type": "string",
          "description": "Third line of the address.",
          "x-intuit-required": "Optional"
        },
        "Line2": {
          "type": "string",
          "description": "Second line of the address.",
          "x-intuit-required": "Optional"
        },
        "Line1": {
          "type": "string",
          "description": "First line of the address.",
          "x-intuit-required": "Optional"
        },
        "PostalCode": {
          "type": "string",
          "description": "Postal code. For example, zip code for USA and Canada",
          "x-intuit-required": "Optional"
        },
        "CountrySubDivisionCode": {
          "type": "string",
          "description": "Region within a country. For example, state name for USA, province name for Canada.",
          "x-intuit-required": "Optional"
        },
        "Id": {
          "type": "string",
          "description": "Unique identifier of the QuickBooks object for the address, autoincremented when the address is changed. This is an internal value included for backwards compatibility and can be ignored.",
          "x-intuit-required": "Required for update"
        }
      }
    },
    "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"
      ]
    },
    "telephonenumber": {
      "type": "object",
      "title": "telephonenumber",
      "properties": {
        "FreeFormNumber": {
          "type": "string",
          "description": "Specifies the telephone number in free form.",
          "x-intuit-required": "Optional"
        }
      }
    },
    "websiteaddress": {
      "type": "object",
      "title": "websiteaddress",
      "properties": {
        "URI": {
          "type": "string",
          "description": "Uniform Resource Identifier for the web site.",
          "x-intuit-required": "Optional"
        }
      }
    }
  }
}