{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/quickbooks/json-schema/quickbooks-billpaymentresponse-schema.json",
  "title": "billpaymentresponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/quickbooks-billpayment-api-openapi.yml#/components/schemas/billpaymentresponse",
  "type": "object",
  "properties": {
    "DocNumber": {
      "type": "string",
      "description": "Reference number for the transaction. If not explicitly provided at create time, a custom value can be provided. If no value is supplied, the resulting DocNumber is null.\nThrows an error when duplicate DocNumber is sent in the request. \nRecommended best practice: check the setting of Preferences:OtherPrefs  before setting DocNumber. If a duplicate DocNumber needs to be supplied, add the query parameter name/value pair, include=allowduplicatedocnum to the URI.\nSort order is ASC by default.",
      "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"
    },
    "PrivateNote": {
      "type": "string",
      "description": "User entered, organization-private note about the transaction. This note does not appear on the invoice to the customer. This field maps to the Memo field on the form.",
      "x-intuit-required": "Optional"
    },
    "VendorRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Reference to the vendor for this transaction. Query the Vendor name list resource to determine the appropriate Vendor object for this reference. Use Vendor.Id and Vendor.Name from that object for VendorRef.value and VendorRef.name, respectively.",
      "x-intuit-required": "Required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "Line": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/line"
      },
      "description": "Individual line items representing zero or more Bill, VendorCredit, and JournalEntry objects linked to this BillPayment object.\nUse Line.LinkedTxn.TxnId as the ID in a separate Bill, VendorCredit, or JournalEntry read request to retrieve details of the linked object.\n\n LinkedTxnLine:",
      "x-intuit-required": "Required"
    },
    "TxnDate": {
      "type": "string",
      "format": "date",
      "description": "The date entered by the user when this transaction occurred.\nFor posting transactions, this is the posting date that affects the financial statements. If the date is not supplied, the current date on the server is used.\n\nSort order is ASC by default.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "current server date",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "TotalAmt": {
      "type": "number",
      "description": "Indicates the total amount associated with this payment. This includes the total of all the payments from the payment line details. If TotalAmt is greater than the total on the lines being paid, the overpayment is treated as a credit and exposed as such on the QuickBooks UI. It cannot be negative.",
      "x-intuit-required": "Required",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "ExchangeRate": {
      "type": "number",
      "description": "The number of home currency units it takes to equal one unit of currency specified by CurrencyRef. Applicable if multicurrency is enabled for the company.",
      "x-intuit-required": "Optional",
      "x-intuit-default": "1, applicable if multicurrency is enabled for the company"
    },
    "APAccountRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "Specifies to which AP account the bill is credited. Query the Account name list resource to determine the appropriate Account object for this reference. Use Account.Id and Account.Name from that object for APAccountRef.value and APAccountRef.name, respectively. The specified account must have Account.Classification set to Liability and Account.AccountSubType set to AccountsPayable.\n\nIf the company has a single AP account, the account is implied. However, it is recommended that the AP Account be explicitly specified in all cases to prevent unexpected errors when relating transactions to each other.",
      "x-intuit-required": "Optional",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "PayType": {
      "type": "string",
      "description": "The payment type. Valid values include: Check, CreditCard",
      "x-intuit-required": "Required"
    },
    "DepartmentRef": {
      "allOf": [
        {
          "$ref": "#/$defs/referencetype"
        }
      ],
      "description": "A reference to a Department object specifying the location of the transaction, as defined using location tracking in QuickBooks Online. Query the Department name list resource to determine the appropriate department object for this reference. Use Department.Id and Department.Name from that object for DepartmentRef.value and DepartmentRef.name, respectively.",
      "x-intuit-required": "Optional"
    },
    "CheckPayment": {
      "allOf": [
        {
          "$ref": "#/$defs/billpaymentcheck"
        }
      ],
      "description": "Information about a check payment for the transaction. Not applicable to Estimate and SalesOrder. Used when PayType is Check.",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "CreditCardPayment": {
      "allOf": [
        {
          "$ref": "#/$defs/billpaymentcreditcard"
        }
      ],
      "description": "Information about a credit card payment for the transaction. Not applicable to Estimate and SalesOrder. Used when PayType is CreditCard.",
      "x-intuit-filterable": true,
      "x-intuit-sortable": true
    },
    "ProcessBillPayment": {
      "type": "boolean",
      "description": "Indicates that the payment should be processed by merchant account service. Valid for QuickBooks companies with credit card processing.",
      "x-intuit-required": "Optional"
    },
    "Id": {
      "type": "string",
      "description": "Unique Identifier for an Intuit entity (object).",
      "x-intuit-required": "Required for update",
      "x-intuit-filterable": true
    },
    "CurrencyRef": {
      "type": "object",
      "x-intuit-type": "CurrencyRefType",
      "description": "Reference to the currency in which all amounts on the associated transaction are expressed. This must be defined if multicurrency is enabled for the company.\n\nMulticurrency is enabled for the company if Preferences.MultiCurrencyEnabled is set to true. Read more about multicurrency support here.Required if multicurrency is enabled for the company",
      "x-intuit-required": "Conditionally required"
    },
    "MetaData": {
      "allOf": [
        {
          "$ref": "#/$defs/modificationmetadata"
        }
      ],
      "description": "Descriptive information about the object. The MetaData values are set by Data Services and are read only for all applications.",
      "x-intuit-required": "Optional"
    }
  },
  "required": [
    "Line",
    "PayType",
    "TotalAmt",
    "VendorRef"
  ],
  "$defs": {
    "billpaymentcheck": {
      "type": "object",
      "title": "billpaymentcheck",
      "properties": {
        "PrintStatus": {
          "type": "string",
          "description": "NeedToPrint\nPrinting status of the invoice.\nValid values:\nNotSet,\nNeedToPrint,\nPrintComplete.",
          "x-intuit-required": "Optional",
          "x-intuit-default": "NeedToPrint"
        },
        "BankAccountRef": {
          "allOf": [
            {
              "$ref": "#/$defs/referencetype"
            }
          ],
          "description": "Reference to the bank account. Query the Account name list resource to determine the appropriate Account object for this reference. Use Account.Id and Account.Name from that object for APAccountRef.value and APAccountRef.name, respectively. The specified account must have Account.AccountType set to Bank and Account.AccountSubType set to Checking.",
          "x-intuit-required": "Required",
          "x-intuit-filterable": true,
          "x-intuit-sortable": true
        }
      },
      "required": [
        "BankAccountRef"
      ]
    },
    "billpaymentcreditcard": {
      "type": "object",
      "title": "billpaymentcreditcard",
      "properties": {
        "CCAccountRef": {
          "allOf": [
            {
              "$ref": "#/$defs/referencetype"
            }
          ],
          "description": "Reference to the credit card account. Query the Account name list resource to determine the appropriate Account object for this reference. Use Account.Id and Account.Name from that object for CCAccountRef.value and CCAccountRef.name, respectively. The specified account must have Account.AccountType set to Credit Card and Account.AccountSubType set to CreditCard.\nInject with data only if the payment was transacted through Intuit Payments API.",
          "x-intuit-required": "Required",
          "x-intuit-filterable": true,
          "x-intuit-sortable": true
        }
      },
      "required": [
        "CCAccountRef"
      ]
    },
    "line": {
      "type": "object",
      "title": "line",
      "properties": {
        "Received": {
          "type": "string",
          "description": "Supported for Purchase Order only. The amount/quantity received of the line, which depends on the type of the line. It can represent the received amount or received quantity based on the line type detail. Applies to existing and new entities."
        },
        "LinkedTxn": {
          "type": "array",
          "items": {},
          "description": "Transaction to which the current entity is related. For example, an invoice line may link to a sales order or estimate.",
          "x-intuit-required": "Optional"
        },
        "Description": {
          "type": "string",
          "description": "Free form text description of the line item that appears in the printed record.",
          "x-intuit-required": "Optional"
        },
        "ProjectRef": {
          "allOf": [
            {
              "$ref": "#/$defs/referencetype"
            }
          ],
          "description": "Reference to the Project ID associated with this transaction.",
          "x-intuit-required": "Conditionally required"
        },
        "LineNum": {
          "type": "number",
          "description": "Specifies the position of the line in the collection of transaction lines. Positive integer",
          "x-intuit-required": "Optional"
        },
        "Amount": {
          "type": "number",
          "description": "The amount of the line item.",
          "x-intuit-required": "Required"
        },
        "Id": {
          "type": "string",
          "description": "The Id of the line item. Its use in requests is as folllows:\nIf\nIdis greater than zero and exists for the company, the request is considered an update operation for a line item.\n\nIf no\nIdis provided, the\nIdprovided is less than or equal to zero, or the\nIdprovided is greater than zero and does not exist for the company then the request is considered a create operation for a line item.\n\nAvailable in all objects that use lines and support the update operation.",
          "x-intuit-required": "Required for update"
        }
      },
      "required": [
        "Amount"
      ]
    },
    "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
        }
      }
    },
    "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"
      ]
    }
  }
}