18 July 2022
Composable Commerce
HTTP API
Enhancement
Audit LogQuotesGraphQL

We have extended the capabilities of Audit Log to include the tracking of changes made on Quotes, Quote Requests, and Staged Quotes. With this enhancement, all Changes performed on Quotes, Quotes Requests and Staged Quotes are tracked from now on and these Changes are now retrievable via API.

Changes:

The following change was introduced in terms of GraphQL SDL:

quote(
  changes: [QuoteChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  id: String!
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_quotes])

quotes(
  changes: [QuoteChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_quotes])

quoteRequest(
  changes: [QuoteRequestChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  id: String!
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_quote_requests])

quoteRequests(
  changes: [QuoteRequestChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_quote_requests])

stagedQuote(
  changes: [StagedQuoteChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  id: String!
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_staged_quotes])

stagedQuotes(
  changes: [StagedQuoteChangeInput!]
  clientId: String
  customerId: String
  date: DateRange
  expand: Boolean
  limit: Int
  offset: Int
  source: Source
  stores: [String!]
  userId: String
  type: Type
): ChangeHistoryQueryResults!
  @auth(permissions: [view_audit_log, view_staged_quotes])

type QuoteLabel {
  key: String
  customer: Reference
  quoteRequest: Reference!
  stagedQuote: Reference!
}

type QuoteRequestLabel {
  key: String
  customer: Reference
}

type StagedQuoteLabel {
  key: String
  customer: Reference
  quoteRequest: Reference!
}

enum QuoteChangeInput {
  changeQuoteState
  setCustomField
  setCustomType
}

enum QuoteRequestChangeInput {
  changeQuoteRequestState
  setCustomField
  setCustomType
}

enum StagedQuoteChangeInput {
  changeStagedQuoteState
  setSellerComment
  setValidTo
  setCustomField
  setCustomType
}