Applying local delivery or in-store pick up options to draft order

Hi again @ozzyonfire

We am confirm this does work with a shipping address in the input. The steps are:

  1. Query draftOrderAvailableDeliveryOptions, and grab the local pickup option’s handle


3. Run the draftOrderCreate mutation with the handle passed in as the shippingLineInput.shippingRateHandle

mutation DraftOrderCreate($input: DraftOrderInput!) {
  draftOrderCreate(input: $input) {
    draftOrder {
      lineItems(first: 100) {
        edges {
          node {
            quantity
            requiresShipping
            title
          }
        }
      }
      shippingLine {
        id
        custom
        shippingRateHandle
        title
        originalPriceSet {
          presentmentMoney {
            amount
            currencyCode
          }
        }
      }
      shippingAddress {
        address1
        city
        provinceCode
        country
      }
    }
    userErrors {
      field
      message
    }
  }
}

input:

{
  "input": {
    "shippingLine": {
      "shippingRateHandle": "4e8227a87f8171a98584cc2959680be7"
    },
    "shippingAddress": {
      "address1": "123 Main St",
      "city": "Waterloo",
      "province": "Ontario",
      "country": "Canada",
      "zip": "A1A 1A1"
    },
    "billingAddress": {
      "address1": "456 Main St",
      "city": "Toronto",
      "province": "Ontario",
      "country": "Canada",
      "zip": "Z9Z 9Z9"
    },
    "lineItems": [
      {
        "title": "Custom product",
        "originalUnitPrice": 100,
        "quantity": 1,
        "requiresShipping": true
      }
    ]
  }
}