---
title: >-
  DraftOrderInput now accepts discountCodes and acceptAutomaticDiscounts. -
  Shopify developer changelog
description: >-
  Shopify’s developer changelog documents all changes to Shopify’s platform.
  Find the latest news and learn about new platform opportunities.
source_url:
  html: >-
    https://shopify.dev/changelog/draftorderinput-now-accepts-discountcodes-and-acceptautomaticdiscounts
  md: >-
    https://shopify.dev/changelog/draftorderinput-now-accepts-discountcodes-and-acceptautomaticdiscounts.md
metadata:
  effectiveApiVersion: 2024-07
  affectedApi:
    - displayName: Admin GraphQL API
      handle: admin-graphql
  primaryTag:
    displayName: API
    handle: api
  secondaryTag:
    displayName: New
    handle: new
  indicatesActionRequired: false
  createdAt: '2024-04-02T12:27:14-04:00'
  postedAt: '2024-04-08T12:09:00-04:00'
  updatedAt: '2024-04-09T09:03:38-04:00'
  effectiveAt: '2024-04-08T12:09:00-04:00'
---

April 8, 2024

Tags:

* Admin GraphQL API
* 2024-07

# DraftOrderInput now accepts discountCodes and acceptAutomaticDiscounts.

As of version 2024-07 of the GraphQL Admin API, DraftOrderInput now accepts discountCodes and acceptAutomaticDiscounts. These optional input fields will allow you to apply discount codes to a draft order and decide whether or not to accept automatic discounts during calculation.

Additionally, a new type field named DraftOrderPlatformDiscount has been added that describes details about how the platfom discount has been allocated across the draft order line items, the discount type, its name, and more.

Learn more about DraftOrderPlatformDiscount on [Shopify.dev](https://shopify.dev/docs/api/admin-graphql/2024-07/input-objects/DraftOrderInput)
