All Release Notes

Added functionality to automatically transition states for Quote Requests, Staged Quotes, and Quotes

24 October 2022
Composable Commerce
HTTP API
Enhancement
QuotesOrdersGraphQL

You can now enable automatic state transitions between various pre-defined states for Quote Requests, Staged Quotes, and Quotes. In particular:

  • When creating a Staged Quote you can transition the referenced Quote Request to the Accepted state using the quoteRequestStateToAccepted field on StagedQuoteDraft.
  • When creating a Quote you can transition the referenced Staged Quote to the Sent state using the stagedQuoteStateToSent field on QuoteDraft.
  • When creating an Order you can transition the referenced Quote to the Accepted state using the quoteStateToAccepted field on OrderFromQuoteDraft. The same functionality is available on the My Order endpoint using MyOrderFromQuoteDraft.

This simplifies the management of Quote states by eliminating the need for an additional API call to transition the state.

Changes:

  • [API] Added optional field stagedQuoteStateToSent to QuoteDraft
  • [API] Added optional field quoteRequestStateToAccepted to StagedQuoteDraft
  • [API] Added optional field quoteStateToAccepted to OrderFromQuoteDraft
  • [API] Added optional field quoteStateToAccepted to MyOrderFromQuoteDraft
  • [GraphQL API] Changed the QuoteDraft type:
    • Input field stagedQuoteStateToSent was added to QuoteDraft type
  • [GraphQL API] Changed the StagedQuoteDraft type:
    • Input field quoteRequestStateToAccepted was added to StagedQuoteDraft type
  • [GraphQL API] Changed the OrderQuoteCommand type:
    • Input field quoteStateToAccepted was added to OrderQuoteCommand type
  • [GraphQL API] Changed the OrderMyQuoteCommand type:
    • Input field quoteStateToAccepted was added to OrderMyQuoteCommand type

The following changes were introduced in terms of GraphQL SDL:

extend input QuoteDraft {
stagedQuoteStateToSent: Boolean = false
}
extend input StagedQuoteDraft {
quoteRequestStateToAccepted: Boolean = false
}
extend input OrderQuoteCommand {
quoteStateToAccepted: Boolean = false
}
extend input OrderMyQuoteCommand {
quoteStateToAccepted: Boolean = false
}