# Sandbox order created via API not visible in sandbox dashboard

**URL:** <https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555>\
**Category:** Questions\
**Tags:** orders-api, payments-api, sandbox\
**Created:** [January 5, 2021, 11:56am UTC](https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555 "2021-01-05T11:56:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mark](https://avatars.discourse-cdn.com/v4/letter/m/e9c0ed/32.png) [@mark](https://developer.squareup.com/forums/u/mark)\
**Post date:** [January 5, 2021, 11:56am UTC](https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555/1 "2021-01-05T11:56:39Z")

</div>

I am using the Orders API to create an order (with a SHIPMENT fulfillment), then the Payments API to create a payment (autocomplete=false) associated with that newly created order. Some time later, I am then using the Payments API to complete payment, and then use the Orders API to update the shipping note and update the SHIPMENT fulfillment state to COMPLETED.

I would expect the order to be visible in the Sandbox seller dashboard (using ‘all orders’ filter), however it is not listed. Interestingly I have notifications (bell icon) that there are new orders, but they are not listed on the orders page.

I have seen the topic [Created Order in Sandbox](https://developer.squareup.com/forums/t/created-order-in-sandbox/171), however I am sure that I have both a fulfillment and that the payment has been completed.

Here is the order data:

```
{
  "id": "P5iQsvTnEgO2jYd4whIVikkWHjRZY",
  "location_id": "TVBH5MQC1VVYY",
  "line_items": [
    {
      "uid": "total",
      "quantity": "1",
      "name": "Order Total",
      "base_price_money": {
        "amount": 3999,
        "currency": "USD"
      },
      "gross_sales_money": {
        "amount": 3999,
        "currency": "USD"
      },
      "total_tax_money": {
        "amount": 0,
        "currency": "USD"
      },
      "total_discount_money": {
        "amount": 0,
        "currency": "USD"
      },
      "total_money": {
        "amount": 3999,
        "currency": "USD"
      },
      "variation_total_price_money": {
        "amount": 3999,
        "currency": "USD"
      }
    }
  ],
  "fulfillments": [
    {
      "uid": "shipment-fulfillment",
      "type": "SHIPMENT",
      "state": "COMPLETED",
      "shipment_details": {
        "recipient": {
          "customer_id": "1NMBQMBMTGTKSCXPNHGX2J8QR8",
          "display_name": "mark@mbtionline.com",
          "email_address": "mark@mbtionline.com"
        },
        "shipping_note": "Order orderUSD01, Invoice InvUSD01",
        "placed_at": "2021-01-04T17:17:37.973Z",
        "packaged_at": "2021-01-04T17:17:53.261Z",
        "shipped_at": "2021-01-04T17:17:53.261Z",
        "in_progress_at": "2021-01-04T17:17:53.261Z"
      }
    }
  ],
  "metadata": {
    "Order": "orderUSD01",
    "Invoice": "InvUSD01"
  },
  "created_at": "2021-01-04T16:48:54.396Z",
  "updated_at": "2021-01-04T17:17:53.262Z",
  "state": "OPEN",
  "version": 6,
  "reference_id": "44e48f1c-5b0d-462d-b5c1-9bf780fee4ab",
  "total_tax_money": {
    "amount": 0,
    "currency": "USD"
  },
  "total_discount_money": {
    "amount": 0,
    "currency": "USD"
  },
  "total_tip_money": {
    "amount": 0,
    "currency": "USD"
  },
  "total_money": {
    "amount": 3999,
    "currency": "USD"
  },
  "tenders": [
    {
      "id": "bhSuDtyypbLOPiGEiOdyBVorUXWZY",
      "location_id": "TVBH5MQC1VVYY",
      "transaction_id": "P5iQsvTnEgO2jYd4whIVikkWHjRZY",
      "created_at": "2021-01-04T16:48:54Z",
      "amount_money": {
        "amount": 3999,
        "currency": "USD"
      },
      "type": "CARD",
      "card_details": {
        "status": "CAPTURED",
        "card": {
          "card_brand": "VISA",
          "last_4": "1111",
          "fingerprint": "sq-1-GS92d4pOeYFco5QzXONkUmR3V-7SPORIkmRIBDr0g1oCgaa6MOcQn446j9eB-kNK8g"
        },
        "entry_method": "ON_FILE"
      },
      "payment_id": "bhSuDtyypbLOPiGEiOdyBVorUXWZY"
    }
  ],
  "total_service_charge_money": {
    "amount": 0,
    "currency": "USD"
  },
  "net_amounts": {
    "total_money": {
      "amount": 3999,
      "currency": "USD"
    },
    "tax_money": {
      "amount": 0,
      "currency": "USD"
    },
    "discount_money": {
      "amount": 0,
      "currency": "USD"
    },
    "tip_money": {
      "amount": 0,
      "currency": "USD"
    },
    "service_charge_money": {
      "amount": 0,
      "currency": "USD"
    }
  },
  "source": {
    "name": "Sandbox for sq0idp-VxTfvNjI-9UhHj7qoHsZDQ"
  },
  "customer_id": "1NMBQMBMTGTKSCXPNHGX2J8QR8"
},

```

Interestingly, further testing/iterations have shown that if I do not set the SHIPMENT fulfillment state to COMPLETED (leave it as PREPARED) **it does appear** in the dashboard. However, I then have to manually mark it as shipped to complete the order. **How can I achieve the same thing via the API?**

---

<div class="post-metadata">

**Author:** ![sjosey](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/sjosey/32/40_2.png) [@sjosey](https://developer.squareup.com/forums/u/sjosey)\
**Post date:** [January 5, 2021, 5:29pm UTC](https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555/2 "2021-01-05T17:29:13Z")

</div>

Hi @mark welcome to the forums!

That is currently a known state that is not supported in the dashboard. An order cannot be `OPEN` while the fulfillment is `COMPLETED`. If you update the order and mark the root order as `COMPLETED`, it should show up in the dashboard.

The dashboard does show `OPEN` orders with `OPEN` fulfillments which is why your latter one works. It also shows `COMPLETED` orders with `COMPLETED fulfillments`, but not `OPEN` orders with `COMPLETED` fulfillments. When using the dashboard to complete an order fulfillment, it would normally automatically mark the root order as `COMPLETED` as well.

---

<div class="post-metadata">

**Author:** ![mark](https://avatars.discourse-cdn.com/v4/letter/m/e9c0ed/32.png) [@mark](https://developer.squareup.com/forums/u/mark)\
**Post date:** [January 5, 2021, 5:41pm UTC](https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555/3 "2021-01-05T17:41:25Z")

</div>

Thanks @sjosey.

So what I need to do is to update the order state to COMPLETED at the same time I update the fulfilment state. I think I had misunderstood and thought it would auto-complete the order when all fulfilments were completed.

---

<div class="post-metadata">

**Author:** ![sjosey](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/sjosey/32/40_2.png) [@sjosey](https://developer.squareup.com/forums/u/sjosey)\
**Post date:** [January 5, 2021, 6:11pm UTC](https://developer.squareup.com/forums/t/sandbox-order-created-via-api-not-visible-in-sandbox-dashboard/1555/4 "2021-01-05T18:11:55Z")

</div>

Yep, that’s correct. If the fulfillment was handled by the dashboard or POS then it would be auto-completed when the fulfillment was completed, but if you’re doing it via the API you will need to manually do it.
