Skip to main content

closeQuote

Requires permission sales:quote:update.

Close a quote: LOST moves it to REJECTED and records lossReason/competitorName/lossNotes/lostAt; WON records winReason/wonAt on an already ACCEPTED/CONVERTED quote (winning itself is conversion or the buyer's accept).

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation CloseQuote($input: CloseQuoteInput!) {
closeQuote(input: $input) {
id
quoteNumber
competitorName
customerName
status
createdAt
convertedToInvoice {
id
invoiceNumber
supplierCode
supplierDisplayName
supplierName
status
}
}
}

Variables:

{
"input": {
"outcome": "LOST",
"quoteId": "id",
"reason": "string"
}
}

Response:

{
"data": {
"closeQuote": {
"id": "id",
"quoteNumber": "string",
"competitorName": "string",
"customerName": "string",
"status": "string",
"createdAt": "2025-01-15T00:00:00Z",
"convertedToInvoice": {
"id": "id",
"invoiceNumber": "string",
"supplierCode": "string",
"supplierDisplayName": "string",
"supplierName": "string",
"status": "APPROVED"
}
}
}
}

Mark a quote as won:

mutation CloseQuote($input: CloseQuoteInput!) {
closeQuote(input: $input) {
id
quoteNumber
status
}
}

Variables:

{
"input": {
"quoteId": "QUOTE_ID",
"outcome": "WON",
"reason": "Customer accepted the quote"
}
}

Response:

{
"data": {
"closeQuote": {
"id": "QUOTE_ID",
"quoteNumber": "QUOTE_NUMBER",
"status": "ACCEPTED"
}
}
}
closeQuote(
input: CloseQuoteInput!
): Quote!

Arguments​

closeQuote.input ● CloseQuoteInput! non-null input​

The outcome, WON or LOST, and the reason.

Type​

Quote object​

A priced offer to a customer, valid until a set date. Converts to a sales order or invoice when accepted.