Wowma!API:出品商品の在庫情報を取得

目次
Wow!manager登録商品の在庫数を取得するAPI
倉庫入れ中を含め、Wow!managerに登録されている商品の在庫数を取得するAPI。多店舗展開するとモール毎の在庫ギャップが生じますが、ギャップの有無をこのAPIで拾うことが出来ます。商品情報取得APでも在庫に関する情報を取得できるので目的によって使い分けをすることがベストです。
APIメソッド:searchStocks
指定した商品の在庫情報を取得する。
REST API / HTTP Method
REST API | HTTP Method |
---|---|
https://api.manager.wowma.jp/wmshopapi/searchStocks | GET |
Request
Header
No | Key | Value | Note |
---|---|---|---|
1 | Authorization | Bearer “アプリケーションキー” | 認証方式と”APIキー”を設定 |
2 | Content-Type | application/x-www-form-urlencoded |
Body (INPUT)
No | 分類 | プロパティ名 | Element | 必須 | 型 | byte | 説明 |
---|---|---|---|---|---|---|---|
1 | 共通 | 店舗ID | shopId | ◎ | long | 18 | 半角数字:18桁 各店舗様へ割り振られた会員番号 |
2 | 共通 | 最大取得件数 | totalCount | – | string | 3 | 半角数字:3桁 データの取得件数(最大値500)を指定 指定なし:デフォルト(10) |
3 | 個別 | 開始件数 | startCount | – | string | 3 | 半角数字:3桁 何件目からデータの取得をはじめるかを指定 (例:データが100件あった場合。 startを「26」にしてmax_resultを「25」にした場合は、 100件あるデータのうち26件目~50件目のデータを取得する。) 指定なし:デフォルト(1) |
4 | 個別 | ロットナンバー | lotNumber | – | long | 18 | 半角数字:18桁 完全一致検索 |
5 | 個別 | 商品code | itemCode | – | string | 128 | 全角:64桁 半角:128桁 店舗内の商品でユニークな項目、部分一致検索 |
6 | 個別 | 出品在庫数下限 | stockCountFrom | – | string | 5 | 半角数字:5桁 範囲検索 在庫区分で通常在庫が選択されている場合のみ指定可能 0~99999個検索例: 出品在庫数下限=0、出品在庫数上限=10とセットすることで 通常在庫10個以下の商品を検索できます。 |
7 | 個別 | 出品在庫数上限 | stockCountTo | – | string | 5 | 半角数字:5桁 範囲検索 在庫区分で通常在庫が選択されている場合のみ指定可能 0~99999個検索例: 出品在庫数下限=0、出品在庫数上限=10とセットすることで 通常在庫10個以下の商品を検索できます。 |
Response
Header
No | Key | Value | Note |
---|---|---|---|
1 | Content-Type | application/xml; charset=utf-8 | 認証方式と”APIキー”を設定 |
Body (OUTPUT)
No | 分類 | プロパティ名 | Element | 型 | byte | 説明 | 通常商品 | 選択肢商品 |
---|---|---|---|---|---|---|---|---|
1 | 共通 | レスポンス | response | group | – | – | – | – |
2 | 共通 | 処理結果 | response.result | group | – | – | – | – |
3 | 共通 | 処理結果コード | response.result.status | string | 1 | 0:成功 1:失敗 |
– | – |
4 | 共通 | エラー情報 | response.result.error | group | – | エラー時のアラート | – | – |
5 | 共通 | エラーコード | response.result.error.code | string | 7 | メッセージ一覧のメッセージIDを参照。 エラー時のアラート |
– | – |
6 | 共通 | エラーメッセージ | response.result.error.message | string | 1000 | メッセージ一覧の詳細メッセージを参照。 エラー時のアラート |
– | – |
7 | 個別 | 処理結果詳細 | searchResult | group | – | – | ○ | ○ |
8 | 個別 | 取得全件数 | searchResult.maxCount | string | 3 | 検索でヒットした件数を返却 | ○ | ○ |
9 | 個別 | 表示件数 | searchResult.resultCount | string | 3 | データの取得件数を表示 | ○ | ○ |
10 | 個別 | 表示開始件数 | searchResult.startCount | string | 3 | 検索結果の何件目からデータの表示を開始しているかを表示 | ○ | ○ |
11 | 個別 | 結果在庫情報 | searchResult.resultStocks | group | – | 検索結果でヒットした数分返却する。 | ○ | ○ |
12 | 個別 | ロットナンバー | searchResult.resultStocks.lotNumber | long | 18 | 検索でヒットした商品のロットナンバーを設定する。 | ○ | ○ |
13 | 個別 | 商品コード | searchResult.resultStocks.itemCode | string | 256 | 検索でヒットした商品の商品コードを設定する。 | ○ | ○ |
14 | 個別 | 在庫区分 | searchResult.resultStocks.stockSegment | string | 1 | 1:通常在庫 2:選択肢別在庫 |
○ | ○ |
15 | 個別 | 通常在庫数 | searchResult.resultStocks.stockCount | string | 5 | – | ○ | – |
16 | 個別 | 通常在庫発送日ID | searchResult.resultStocks.stockShippingDayId | string | 10 | – | ○ | – |
17 | 個別 | 通常在庫発送日表示文言 | searchResult.resultStocks.stockShippingDayDispTxt | string | 40 | – | ○ | – |
18 | 個別 | 残在庫表示区分 | searchResult.resultStocks.displayStockSegment | string | 1 | 1:在庫数を表示しない。 2:在庫数を表示する。 3:指定した在庫数以下の場合表示する。 |
○ | – |
19 | 個別 | 在庫表示閾値 | searchResult.resultStocks.displayStockThreshold | string | 5 | [残在庫表示区分]が 「指定した在庫数以下の場合表示する。」に該当する場合のみ値を返却する。 |
○ | – |
20 | 個別 | 選択肢別在庫横軸項目名 | searchResult.resultStocks.choicesStockHorizontalItemName | string | 50 | 例:色 | – | ○ |
21 | 個別 | 選択肢別在庫横軸 | searchResult.resultStocks.choicesStockHorizontals | group | – | 選択肢別在庫の横軸の設定 入力件数:1~20 |
– | ○ |
22 | 個別 | 選択肢別在庫横軸コード | searchResult.resultStocks.choicesStockHorizontals.choicesStockHorizontalCode | string | 255 | 例:-R | – | ○ |
23 | 個別 | 選択肢別在庫横軸名 | searchResult.resultStocks.choicesStockHorizontals.choicesStockHorizontalName | string | 100 | 例:赤 | – | ○ |
24 | 個別 | 選択肢別在庫横軸順序 | searchResult.resultStocks.choicesStockHorizontals.choicesStockHorizontalSeq | string | 2 | 選択肢別在庫の横軸の数値。 範囲:1~20 |
– | ○ |
25 | 個別 | 選択肢別在庫縦軸項目名 | searchResult.resultStocks.choicesStockVerticalItemName | string | 50 | 例:サイズ | – | ○ |
26 | 個別 | 選択肢別在庫縦軸 | searchResult.resultStocks.choicesStockVerticals | group | – | 選択肢別在庫の縦軸の設定 入力件数:1~40 |
– | ○ |
27 | 個別 | 選択肢別在庫縦軸コード | searchResult.resultStocks.choicesStockVerticals.choicesStockVerticalCode | string | 255 | 例:-S | – | ○ |
28 | 個別 | 選択肢別在庫縦軸名 | searchResult.resultStocks.choicesStockVerticals.choicesStockVerticalName | string | 100 | 例:S | – | ○ |
29 | 個別 | 選択肢別在庫縦軸順序 | searchResult.resultStocks.choicesStockVerticals.choicesStockVerticalSeq | string | 2 | 選択肢別在庫の縦軸の数値。 範囲:1~40 |
– | ○ |
30 | 個別 | 選択肢別在庫 | searchResult.resultStocks.choicesStocks | group | – | 在庫数の設定(最大20×40=800件) | – | ○ |
31 | 個別 | 選択肢別在庫横軸コード | searchResult.resultStocks.choicesStocks.choicesStockHorizontalCode | string | 100 | – | – | ○ |
32 | 個別 | 選択肢別在庫縦軸コード | searchResult.resultStocks.choicesStocks.choicesStockVerticalCode | string | 100 | – | – | ○ |
33 | 個別 | 選択肢別在庫数 | searchResult.resultStocks.choicesStocks.choicesStockCount | string | 5 | – | – | ○ |
34 | 個別 | 選択肢別在庫発送日ID | searchResult.resultStocks.choicesStocks.choicesStockShippingDayId | string | 10 | – | – | ○ |
35 | 個別 | 選択肢別在庫発送日表示文言 | searchResult.resultStocks.choicesStocks.choicesStockShippingDayDispTxt | string | 40 | – | – | ○ |
36 | 個別 | 選択肢別在庫上説明 | searchResult.resultStocks.choicesStockUpperDescription | string | 250 | HTML使用可、使用する場合はエスケープすること。エスケープについてはAPI共通仕様参照。 | – | ○ |
37 | 個別 | 選択肢別在庫下説明 | searchResult.resultStocks.choicesStockLowerDescription | string | 250 | HTML使用可、使用する場合はエスケープすること。エスケープについてはAPI共通仕様参照。 | – | ○ |
38 | 個別 | 残選択肢別在庫表示区分 | searchResult.resultStocks.displayChoicesStockSegment | string | 1 | 1:在庫数を表示しない。 2:在庫数を表示する。 3:指定した在庫数以下の場合、「△」を表示。 |
– | ○ |
39 | 個別 | 選択肢別在庫表示閾値 | searchResult.resultStocks.displayChoicesStockThreshold | string | 5 | [残在庫表示区分]が 「3:指定した在庫数以下の場合、「△」を表示。」に該当する場合のみ値を返却する。 |
– | ○ |
40 | 個別 | 在庫切れメッセージ | searchResult.resultStocks.displayBackorderMessage | string | 64 | – | ○ | ○ |
-
前の記事
Wowma!API:商品情報更新API(Ver.シングル) 2018.09.24
-
次の記事
Wowma!API:登録商品の在庫数更新API 2018.09.24
https://qol-kk.com/wp2/blog/2018/09/24/post-653/
Can this method also be used for getting stock information of multiple products ?
if yes then how ?
It is an API to get the number of stock of the specified product. For various scripts, you can obtain a list of URLs in advance and turn it with [foreach] to obtain stock of multiple products.