# 在庫管理について

**URL:** <https://community.shopify.com/t/topic/387916>\
**Category:** 技術的なQ＆A\
**Created:** [January 18, 2025, 6:29am UTC](https://community.shopify.com/t/topic/387916 "2025-01-18T06:29:12Z")\
**Posts on this page:** 2\
**Page:** 1

## AI-generated summary

**質問内容:**
APIを使用して在庫情報を更新する際、手持ちや販売可能数だけでなく、販売不可在庫（破損、安全在庫など）の内訳も更新したいという要望。

**回答のポイント:**
- 管理画面上の販売不可在庫の内訳数値を直接更新することは**できない**
- 安全在庫(safety_stock)をAPIで変更した場合:
  - APIでは安全在庫の数値を正しく取得できる
  - しかし管理画面上では「利用できない」と表示されるのみで、内訳の「安全在庫」には数値が反映されない
- Shopify公式ドキュメントでも、安全在庫は管理画面では「Unavailable」として表示されると明記されている

**推奨アクション:**
さらに詳細が必要な場合は、Shopify Partnerダッシュボードから公式サポートへ問い合わせることを推奨。

**ステータス:** 技術的制限により、要望の実現は困難な可能性が高い。

<div class="post-metadata">

**Author:** ![sumi3](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@sumi3](https://community.shopify.com/u/sumi3)\
**Post date:** [January 18, 2025, 6:29am UTC](https://community.shopify.com/t/topic/387916/1 "2025-01-18T06:29:12Z")

</div>

在庫情報をAPIで更新したいのですが、販売不可(破損、安全在庫）なども更新したいのですが、

手持ち、販売可能数の更新方法は調査できたのですが、販売不可の内訳も更新したいと思ってます

---

<div class="post-metadata">

**Author:** ![Qcoltd](https://yyz1.discourse-cdn.com/shopifyforum/user_avatar/community.shopify.com/qcoltd/32/900_2.png) [@Qcoltd](https://community.shopify.com/u/Qcoltd)\
**Post date:** [January 21, 2025, 4:27am UTC](https://community.shopify.com/t/topic/387916/2 "2025-01-21T04:27:05Z")

</div>

@sumi3 様

> 手持ち、販売可能数の更新方法は調査できたのですが、販売不可の内訳も更新したいと思ってます

管理画面上の内訳数値を更新することはできないようです。

[https://shopify.dev/docs/apps/build/orders-fulfillment/inventory-management-apps](https://shopify.dev/docs/apps/build/orders-fulfillment/inventory-management-apps)

例えば安全在庫(safety\_stock)については下記のように記載があります。

```markup
safety_stock

The on-hand units that are set aside to help guard against overselling.

Inventory quantities in a safety_stock state display as Unavailable to merchants that are tracking inventory in the Shopify admin.

```

マーチャントには、Shopify管理画面上では、「安全在庫」の数は「利用できない」として表示される。

とのことです。

APIで、安全在庫の数を変更した場合、

下記のようにAPIで安全在庫の数を取得すると、しっかり安全在庫の数を取得できますが、

[https://shopify.dev/docs/api/admin-graphql/2024-07/queries/inventoryLevel](https://shopify.dev/docs/api/admin-graphql/2024-07/queries/inventoryLevel)

管理画面上では、「利用できない」としか表示されず、内訳の「安全在庫」には数が反映されていないことを確認しました。

もし、上記、ご存知の上でのご質問でしたら、

Shopify Partnerのダッシュボードから、Shopify Partnerサポートにお問い合わせいただくと良いかと思います。

ご参考まで。

(キュー田辺)
