All Release Notes

Added support for creating and deleting staged values in Standalone Prices

31 August 2023
Composable Commerce
HTTP API
Enhancement
Pricing and DiscountsGraphQL

You can now create staged values while creating Standalone Prices. Previously, you could only set staged values on existing Standalone Prices after they have been created. Additionally, you can now delete staged values in Standalone Prices. Previously, you could only delete staged values by applying the staged changes to the Standalone Price, or by deleting the respective Standalone Price.

Changes:

  • [API] Added staged field to StandalonePriceDraft.
  • [API] Added StagedPriceDraft type to the Standalone Prices API.
  • [API] Added Remove Staged Values update action to the Standalone Prices API.
  • [API] Added StandalonePriceStagedChangesRemoved Message.
  • [GraphQL API] Added the following types to the GraphQL schema: StagedPriceDraft, RemoveStagedChanges, StandalonePriceStagedChangesRemoved .
  • [GraphQL API] Changed the CreateStandalonePrice type:
    • Added the staged field to the StandalonePriceUpdateAction type.
  • [GraphQL API] Changed the StandalonePriceUpdateAction type:
    • Input field removeStagedChanges was added to StandalonePriceUpdateAction type.

The following changes were introduced in terms of GraphQL SDL:

input StagedPriceDraft {
value: BaseMoneyInput!
}
extend type CreateStandalonePrice {
staged: StagedPriceDraft
}
extend input StandalonePriceUpdateAction {
removeStagedChanges: RemoveStagedChanges
}
type StandalonePriceStagedChangesRemoved implements MessagePayload {
stagedChanges: StagedStandalonePrice
type: String!
}
input RemoveStagedChanges {
dummy: String
}