Skip to content

QuickBooks: Delete a change order

QuickBooks changeorder.delete: arguments, response, policy and SDK examples.

← Changeorder operations · Get started

Operation quickbooks.changeorder.delete_a_change_order

Provider route: POST /v3/company/{realmID}/changeorder. Alter supplies the connection’s credentials and routing.

Install @alter-ai/sdk @alter-ai/quickbooks with npm, or alter-sdk-quickbooks with pip. Supply your connected customer’s grant ID and the arguments described below.

import { App } from "@alter-ai/sdk";
import { QuickBooksIntegration } from "@alter-ai/quickbooks";
async function execute(input: Parameters<QuickBooksIntegration["changeorder"]["delete"]>[0]) {
const app = new App({ apiKey: process.env.ALTER_API_KEY! });
try {
const provider = new QuickBooksIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! });
const call = await provider.changeorder.delete(input);
const result = await call.wait();
return result.bodyJson();
} finally {
await app.close();
}
}
import os
from alter_sdk import App
from alter_sdk_quickbooks import QuickBooksIntegration
async def execute(arguments):
async with App(api_key=os.environ["ALTER_API_KEY"]) as app:
provider = QuickBooksIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]})
call = await provider.changeorder.delete(arguments)
result = await call.wait()
return result.body_json()
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: not allowed
queryobjectOptionalAdditional keys: not allowed
query.minorversionintegerOptionalMust equal: 75
query.requestidstringOptionalMinimum length: 1
bodyModelRequired within parentExpand Delete a change order — request body — body

Referenced models: Delete a change order — request body — body

Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.

FieldTypePresenceDescription and constraints
$objectRootAdditional keys: allowed
timestringOptional
ChangeOrderModelOptionalExpand Read a change order — response body — Change Order

Referenced models: Read a change order — response body — Change Order

36 more schemas are linked from the tables above, on the schema pages.

Read a change order — response body — Change Order
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: allowed
AcceptedBystringOptionalName of the customer or representative who accepted the change order. Populated when TxnStatus is set to Accepted .
AcceptedDatestringOptionalDate the change order was accepted. Populated when TxnStatus is set to Accepted .
ApplyTaxAfterDiscountJSONOptionalIf false or null, sales tax is calculated first and then any discount is applied. If true , the discount is subtracted first and then sales tax is calculated.
ApplyTaxAfterDiscount (anyOf 1)booleanAlternative
ApplyTaxAfterDiscount (anyOf 2)stringAlternativeKnown values: true, false
ApplyTaxAfterDiscount (anyOf 3)nullAlternative
BillEmailModelOptionalExpand Full update companyinfo — request body — body Email
Email address where the change order is sent. Required when EmailStatus is set to NeedToSend .
Conditionally required
CustomerMemoModelOptionalExpand Read an invoice — response body — Invoice Customer Memo
User-entered message to the customer; visible on the Change Order document sent to the customer.
CustomerRefModelOptionalExpand Read an item — response body — Item Class Ref
Reference to the customer associated with this change order. Must match the customer on the parent project estimate. Use Customer.Id and Customer.DisplayName from the Customer object for CustomerRef.value and CustomerRef.name , respectively.
DocNumberJSONOptionalReference number for the change order (for example, CO-001 ). If not provided, the value is null.
DocNumber (anyOf 1)stringAlternative
DocNumber (anyOf 2)nullAlternative
EmailStatusstringOptionalEmail status of the change order. Valid values: NotSet , NeedToSend , EmailSent .
ExpirationDatestringOptionalDate by which the change order must be accepted before it expires.
IdstringOptionalUnique identifier for this object.
Read only: true
LinearrayOptionalIndividual line items describing the work being added or removed. Supports SalesItemLineDetail and SubTotalLineDetail line types. Every line must include a LinkedTxn array referencing the parent project estimate with TxnType: "Estimate" . All lines must reference the same parent estimate. The Line array uses full-replace behavior on update — lines omitted from an update request are deleted.
Line[]JSONEach item
Line[] (anyOf 1)ModelAlternativeExpand Read an invoice — response body — Invoice Line item Amount, Custom Extensions, Description, Detail Type, Id, Line Num, Sales Item Line Detail
Line[] (anyOf 2)ModelAlternativeExpand Read an invoice — response body — Invoice Line item Amount, Description, Detail Type, Id, Line Num, Sub Total Line Detail
Line[] (anyOf 3)ModelAlternativeExpand Read an invoice — response body — Invoice Line item Amount, Description, Detail Type, Discount Line Detail, Id, Line Num
Line[] (anyOf 4)ModelAlternativeExpand Read an invoice — response body — Invoice Line item Amount, Description, Description Line Detail, Detail Type, Id, Line Num
LinkedTxnarrayOptionalOne or more linked transaction references at the header level, reflecting the parent project estimate. Also appears on each line item. Use LinkedTxn.TxnId as the ID in a separate Estimate read request to retrieve details of the linked object. TxnType must always be Estimate .
LinkedTxn[]ModelEach itemExpand Read a bill — response body — Bill Linked Txn item
MetaDataModelOptionalExpand Read a bill — response body — Bill Meta Data
Descriptive information about the object. The MetaData values are set by Data Services and are read only for all applications.
PrintStatusstringOptionalPrinting status of the change order. Valid values: NotSet , NeedToPrint , PrintComplete .
PrivateNotestringOptionalOrganization-private note about the change order. This note does not appear on documents sent to the customer.
ProjectRefModelOptionalExpand Read an item — response body — Item Class Ref
Reference to the project this change order belongs to. Must reference an active project. Without a valid ProjectRef , the change order will not appear in the Projects dashboard.
SyncTokenstringOptionalVersion 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 fail. Only the latest version of the object is maintained by QuickBooks Online.
Read only: true
TotalAmtJSONOptionalTotal amount of the transaction including all line charges and taxes. Calculated by QuickBooks business logic from the sum of all line Amount values plus applicable tax. Do not include in create or update request bodies; any value supplied is overwritten.
Decimal string
Read only: true
TotalAmt (anyOf 1)JSONAlternative
TotalAmt (anyOf 1) (anyOf 1)numberAlternative
TotalAmt (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
TotalAmt (anyOf 2)stringAlternative
TotalCostAmountJSONOptionalTotal cost amount of the transaction, calculated from the sum of all line CostAmount values. Calculated by QuickBooks business logic; any value supplied is overwritten.
Decimal string
Read only: true
TotalCostAmount (anyOf 1)JSONAlternative
TotalCostAmount (anyOf 1) (anyOf 1)numberAlternative
TotalCostAmount (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
TotalCostAmount (anyOf 2)stringAlternative
TxnDatestringOptionalThe date entered by the user when this transaction occurred. For posting transactions, this is the posting date that affects the financial statements. If not supplied, the current date on the server is used. Sort order is ASC by default.
TxnStatusstringOptionalCurrent status of the change order. Valid values: Pending (default — created but not yet reviewed), Accepted (customer approved; project contracted total increases accordingly), Closed (converted to an Invoice or manually closed), Rejected (customer declined; does not affect project total).
TxnTaxDetailModelOptionalExpand Read a bill — response body — Bill Txn Tax Detail
Tax details for the transaction. Captures sales taxes calculated based on tax codes referenced by the transaction lines.

Referenced models: Read an invoice — response body — Invoice Line item Amount, Description, Description Line Detail, Detail Type, Id, Line Num, Read an invoice — response body — Invoice Line item Amount, Description, Detail Type, Discount Line Detail, Id, Line Num, Full update companyinfo — request body — body Email, Read a bill — response body — Bill Linked Txn item, Read an invoice — response body — Invoice Customer Memo, Read a bill — response body — Bill Meta Data, Read an item — response body — Item Class Ref, Read an invoice — response body — Invoice Line item Amount, Custom Extensions, Description, Detail Type, Id, Line Num, Sales Item Line Detail, Read an invoice — response body — Invoice Line item Amount, Description, Detail Type, Id, Line Num, Sub Total Line Detail, Read a bill — response body — Bill Txn Tax Detail

Read an invoice — response body — Invoice Line item Amount, Description, Detail Type, Discount Line Detail, Id, Line Num
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: allowed
AmountJSONOptionalThe amount of the line item.
Decimal string
Amount (anyOf 1)JSONAlternative
Amount (anyOf 1) (anyOf 1)numberAlternative
Amount (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
Amount (anyOf 2)stringAlternative
DescriptionstringOptionalFree form text description of the line item that appears in the printed record.
DetailTypestringOptionalSet to DiscountLineDetail for this type of line.
DiscountLineDetailModelOptionalExpand Read a reimburse charge — response body — Reimburse Charge Line item Reimburse Line Detail
Discount detail type for the entire transaction. This is in contrast to a discount applied to a specific line. The company preference Sales Form Entry | Discounts must be enabled for this type of line to be available. Must be enabled for this type of line to be available.
IdstringOptionalThe Id of the line item. Its use in requests is as folllows: If Id is greater than zero and exists for the company, the request is considered an update operation for a line item. If no Id is provided, the Id provided is less than or equal to zero, or the Id provided is greater than zero and does not exist for the company then the request is considered a create operation for a line item. Available in all objects that use lines and support the update operation. Not supported for BillPayment, Estimate, Invoice, or Payment objects.
Read only: true
LineNumJSONOptionalSpecifies the position of the line in the collection of transaction lines. Positive integer.
Decimal string
LineNum (anyOf 1)JSONAlternative
LineNum (anyOf 1) (anyOf 1)numberAlternative
LineNum (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
LineNum (anyOf 2)stringAlternative

Referenced models: Read a reimburse charge — response body — Reimburse Charge Line item Reimburse Line Detail

SDK function policy ID: quickbooks.changeorder.delete_a_change_order. Catalog operation: changeorder/delete. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.

Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.

Pinned query parameters: {"operation": "delete"}

Official provider source

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand how our website, product, and documentation are used.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

Advertising

Shares visits and sign-ups with Meta, Reddit, and X so we can measure which of our ads work.

You can change these choices at any time from Cookie settings.